Skip to content

Commit

Permalink
some cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
Adammatthiesen committed Jan 18, 2024
1 parent 414cb78 commit dd0f36b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
11 changes: 10 additions & 1 deletion index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand All @@ -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: '/',
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -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",
Expand Down

0 comments on commit dd0f36b

Please sign in to comment.