Chore: Upgrade to AIK
& Massive Overhaul to internal processing #78
|
@ -70,7 +70,7 @@ export default defineConfig({
|
|||
disableDefault404: false, // Allows the user to disable the default `/404 page, to be able to create their own under `/src/pages/404.astro`.
|
||||
enableRSSFeed: true, // Allows the user to Enable or disable RSS Feed Generation. Default: true
|
||||
enableOGImages: true, // Allows the user to Enable or disable OG Image Generation. Default: true
|
||||
fullConsoleLogs: false, // Show the full Log output from All parts of Astro-GhostCMS
|
||||
verbose: false, // Show the full Log output from All parts of Astro-GhostCMS
|
||||
Integrations: {
|
||||
// This allows user config passthrough from Astro-GhostCMS to the Included Integrations
|
||||
robotsTxt: {
|
||||
|
|
|
@ -25,6 +25,7 @@ const ENV = loadEnv("all", process.cwd(), "CONTENT_API");
|
|||
|
||||
|
||||
// Import User Configuration Zod Schema
|
||||
import { GhostUserConfigSchema } from "./schemas/userconfig";
|
||||
import type { string } from "astro/zod";
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
|
||||
/** Astro-GhostCMS Integration
|
||||
* @description This integration allows you to use GhostCMS as a headless CMS for your Astro project
|
||||
|
@ -47,6 +48,8 @@ export default defineIntegration({
|
|||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
injectRoute,
|
||||
logger,
|
||||
}) => {
|
||||
// Set up verbose logging
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
const verbose = options.verbose;
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
// Configure Loggers
|
||||
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
|
||||
const GhostENVLogger = logger.fork(
|
||||
|
@ -54,23 +57,35 @@ export default defineIntegration({
|
|||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
"ENV Check",
|
||||
)}`,
|
||||
);
|
||||
// Configure Integration Loggers & verbose logging
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
const GhostIntegrationLogger = logger.fork(
|
||||
`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(
|
||||
"Integrations",
|
||||
)}`,
|
||||
);
|
||||
const intLogInfo = (message:string) => {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
if (verbose) {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
GhostIntegrationLogger.info(message);
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
}
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
};
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
// Configure Route Logger & verbose logging
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
const GhostRouteLogger = logger.fork(
|
||||
`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(
|
||||
"Router",
|
||||
)}`,
|
||||
);
|
||||
const routeLogInfo = (message:string) => {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
if (verbose) {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
GhostRouteLogger.info(message);
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
}
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
};
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
|
||||
// Setup Watch Integration for Hot Reload during DEV
|
||||
watchIntegration(resolve());
|
||||
GhostLogger.info("Initializing @matthiesenxyz/astro-ghostcms...");
|
||||
|
||||
// Set up verbose logging
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
const verbose = options.fullConsoleLogs;
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
|
||||
// Check for GhostCMS environment variables
|
||||
GhostENVLogger.info(
|
||||
|
@ -136,77 +151,49 @@ export default defineIntegration({
|
|||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
verbose,
|
||||
}),
|
||||
);
|
||||
} else if (verbose) {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
} else {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
intLogInfo(c.gray("Theme Provider is disabled"));
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
}
|
||||
|
||||
// Satori OG Images
|
||||
if (options.enableOGImages) {
|
||||
addIntegration(ghostOGImages({ verbose }));
|
||||
} else if (verbose) {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
GhostIntegrationLogger.info(
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
c.gray("OG Image Provider is disabled"),
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
);
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
} else {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
intLogInfo(c.gray("OG Image Provider is disabled"));
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
}
|
||||
|
||||
// RSS Feed
|
||||
if (options.enableRSSFeed) {
|
||||
addIntegration(ghostRSS({ verbose }));
|
||||
} else if (verbose) {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
GhostIntegrationLogger.info(c.gray("RSS Feed is disabled"));
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
} else {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
intLogInfo(c.gray("RSS Feed is disabled"));
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
}
|
||||
|
||||
// @ASTROJS/SITEMAP
|
||||
if (!hasIntegration("@astrojs/sitemap")) {
|
||||
if (verbose) {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
GhostIntegrationLogger.info(
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
c.bold(
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
c.magenta(`Adding ${c.blue("@astrojs/sitemap")} integration`),
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
),
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
);
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
}
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
intLogInfo(c.bold(c.magenta(`Adding ${c.blue("@astrojs/sitemap")} integration`)));
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
addIntegration(sitemap(options.Integrations?.sitemap));
|
||||
} else if (verbose) {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
GhostIntegrationLogger.info(
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
c.gray(
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
"@astrojs/sitemap integration already exists, skipping...",
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
),
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
);
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
} else {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
intLogInfo(c.gray("@astrojs/sitemap integration already exists, skipping..."));
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
}
|
||||
// ASTRO-ROBOTS-TXT
|
||||
if (!hasIntegration("astro-robots-txt")) {
|
||||
if (verbose) {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
GhostIntegrationLogger.info(
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
c.bold(
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
c.magenta(`Adding ${c.blue("astro-robots-txt")} integration`),
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
),
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
);
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
}
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
intLogInfo(c.bold(c.magenta(`Adding ${c.blue("astro-robots-txt")} integration`)));
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
addIntegration(robotsTxt(options.Integrations?.robotsTxt));
|
||||
} else if (verbose) {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
GhostIntegrationLogger.info(
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
c.gray(
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
"astro-robots-txt integration already exists, skipping...",
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
),
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
);
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
} else {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
intLogInfo(c.gray("astro-robots-txt integration already exists, skipping..."));
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
}
|
||||
|
||||
// Set up default 404 page
|
||||
if (!options.disableDefault404) {
|
||||
if (verbose) {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
GhostRouteLogger.info(
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
c.bold(c.cyan("Setting up default 404 page")),
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
);
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
}
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
routeLogInfo(c.bold(c.cyan("Setting up default 404 page")));
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
injectRoute({
|
||||
pattern: "/404",
|
||||
entrypoint: `${name}/404.astro`,
|
||||
prerender: true,
|
||||
});
|
||||
} else if (verbose) {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
GhostRouteLogger.info(
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
c.gray("Default 404 page is disabled, Skipping..."),
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
);
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
} else {
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
routeLogInfo(c.gray("Default 404 page is disabled, Skipping..."));
|
||||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
||||
}
|
||||
|
||||
// Add virtual imports for user configuration
|
||||
|
|
|||
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]()
```suggestion
} else if (verbose) {
GhostIntegrationLogger.info(c.gray("Theme Provider is disabled"));
}
```
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() same here same here
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() is there a reason for not importing it at the top of the file? if yes, I think you can use is there a reason for not importing it at the top of the file? if yes, I think you can use `resolve` from `createResolver` for the path
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() ah this pulls the version from the user's project? ah this pulls the version from the user's project?
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() I ALWAYS FORGET YOU CAN DO I ALWAYS FORGET YOU CAN DO `else if` vscode should complain if you do an `else { if()` lol
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() i think if you have eslint you can enable such a rule i think if you have eslint you can enable such a rule
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() grabs the current installed one from grabs the current installed one from `astro-ghostcms` local version and compares to the latestversion from NPM :P I did actually try to use the `resolve()` util but that just grabbed the playgrounds package.json ironically...
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() Instead of all these manual checks for
Or could be a Florian special and return a console log function:
Instead of all these manual checks for `verbose` you'd probably be better off with a util function which checks it instead.
```ts
const log = message => {
if (verbose) {
console.log(...)
}
}
```
Or could be a Florian special and return a console log function:
```ts
const createLogger = verbose => message => {
if (verbose) {
console.log(...)
}
}
const log = createLogger(options.verbose)
log(whatever) // now you don't have to check everywhere
```
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() added in new commit, since im not using console.log had to modify it for my usage a little added in new commit, since im not using console.log had to modify it for my usage a little
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() Okay i fixed that issue. Now using Okay i fixed that issue. Now using `resolve()` properly 😄
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() This logging function could also be extracted
This logging function could also be extracted
```ts
const formattedMessage = message => `${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
![]() Updated...
Updated...
```ts
// Configure Loggers
const GhostLogger = logger.fork(c.bold(c.blue("👻 Astro-GhostCMS")));
const loggerTagged = (message: string) => {
return logger.fork(`${c.bold(c.blue("👻 Astro-GhostCMS"))}${c.gray("/")}${c.blue(message)}`)
}
// Configure ENV Logger
const GhostENVLogger = loggerTagged("ENV Check");
// Configure Integration Loggers & verbose logging
const GhostIntegrationLogger = loggerTagged("Integrations");
// Configure Route Logger & verbose logging
const GhostRouteLogger = loggerTagged("Router");
```
|
|
@ -40,7 +40,7 @@ export const GhostUserConfigSchema = z.object({
|
|||
/** Allows the user to turn on/off Full Console Logs
|
||||
* @default true
|
||||
*/
|
||||
fullConsoleLogs: z.boolean().optional().default(false),
|
||||
verbose: z.boolean().optional().default(false),
|
||||
/** OPTIONAL - Integrations Configuration
|
||||
* This option allows the user to configure the included integrations
|
||||
* Options shown are the availble options
|
||||
|
|
|
@ -14,7 +14,7 @@ export default defineConfig({
|
|||
ThemeProvider: {
|
||||
theme: "@matthiesenxyz/astro-ghostcms-brutalbyelian",
|
||||
},
|
||||
fullConsoleLogs: false,
|
||||
verbose: false,
|
||||
}),
|
||||
],
|
||||
});
|
||||
|
|
same here
same here
same here
same here
same here
same here
is there a reason for not importing it at the top of the file? if yes, I think you can use
resolve
fromcreateResolver
for the pathis there a reason for not importing it at the top of the file? if yes, I think you can use
resolve
fromcreateResolver
for the pathThis is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
This is simply to display any new version during dev-mode only... There is a check for latest version and it compares the local version :D
ah this pulls the version from the user's project?
ah this pulls the version from the user's project?
I ALWAYS FORGET YOU CAN DO
else if
vscode should complain if you do anelse { if()
lolI ALWAYS FORGET YOU CAN DO
else if
vscode should complain if you do anelse { if()
loli think if you have eslint you can enable such a rule
i think if you have eslint you can enable such a rule
grabs the current installed one from
astro-ghostcms
local version and compares to the latestversion from NPM :P I did actually try to use theresolve()
util but that just grabbed the playgrounds package.json ironically...grabs the current installed one from
astro-ghostcms
local version and compares to the latestversion from NPM :P I did actually try to use theresolve()
util but that just grabbed the playgrounds package.json ironically...Instead of all these manual checks for
verbose
you'd probably be better off with a util function which checks it instead.Or could be a Florian special and return a console log function:
Instead of all these manual checks for
verbose
you'd probably be better off with a util function which checks it instead.Or could be a Florian special and return a console log function:
added in new commit, since im not using console.log had to modify it for my usage a little
added in new commit, since im not using console.log had to modify it for my usage a little
Okay i fixed that issue. Now using
resolve()
properly 😄Okay i fixed that issue. Now using
resolve()
properly 😄This logging function could also be extracted
This logging function could also be extracted
Updated...
Updated...