some cleanup
This commit is contained in:
parent
414cb7836d
commit
dd0f36b84e
11
index.ts
11
index.ts
|
@ -2,9 +2,11 @@ import type { AstroIntegration } from "astro"
|
|||
import { ZodError, type SafeParseError, type SafeParseSuccess } from "astro/zod"
|
||||
import { UserConfigSchema, type UserConfig } from "./src/utils/UserConfigSchema"
|
||||
|
||||
const pkg = '@matthiesenxyz/astro-ghostcms'
|
||||
|
||||
export default function GhostCMS(options: UserConfig): AstroIntegration {
|
||||
return {
|
||||
name: '@matthiesenxyz/astro-ghostcms',
|
||||
name: pkg,
|
||||
hooks: {
|
||||
'astro:config:setup': async ({
|
||||
injectRoute,
|
||||
|
@ -23,6 +25,13 @@ export default function GhostCMS(options: UserConfig): AstroIntegration {
|
|||
|
||||
const entry = o.data.theme
|
||||
|
||||
if (entry === pkg) {
|
||||
logger.info("Injecting Theme: astro-ghostcms-basetheme")
|
||||
} else {
|
||||
logger.info(`Injecting Theme: ${entry}`)
|
||||
}
|
||||
|
||||
|
||||
logger.info("Injecting Route: /")
|
||||
injectRoute({
|
||||
pattern: '/',
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "@matthiesenxyz/astro-ghostcms",
|
||||
"description": "Astro GhostCMS integration to allow easier importing of GhostCMS Content",
|
||||
"version": "2.0.7",
|
||||
"version": "2.0.8",
|
||||
"author": "MatthiesenXYZ (https://matthiesen.xyz)",
|
||||
"type": "module",
|
||||
"license": "MIT",
|
||||
|
|
Loading…
Reference in New Issue