ready for realease...
This commit is contained in:
parent
324952fce6
commit
0c9232a2bd
|
@ -0,0 +1,2 @@
|
||||||
|
CONTENT_API_KEY=a33da3965a3a9fb2c6b3f63b48
|
||||||
|
CONTENT_API_URL=https://ghostdemo.matthiesen.xyz
|
|
@ -2,10 +2,11 @@
|
||||||
|
|
||||||
Astro minimum Version: **Astro v4.0**
|
Astro minimum Version: **Astro v4.0**
|
||||||
|
|
||||||
This Integration is 2 parts. Firstly, there is the API portion that uses the `@tryghost/content-api` to create the link between astro and GhostCMS. From there we move to the Second Part, which is a theme pre-programmed to pull ALL of its data from GhostCMS iteself instead of storing any local data.
|
This Integration is 2 parts. Firstly, there is the API portion that uses the `@tryghost/content-api` to create the link between astro and GhostCMS. From there we move to the Second Part, which is a theme pre-programmed to pull ALL of its data from GhostCMS iteself instead of storing any data locally outside of Build.
|
||||||
|
|
||||||
- *This package contains a independent copy of the tryghost content-api.js that is used to establish the connection so this package dose not depend on `@tryghost/content-api` package.*
|
- *This package contains a independent copy of the tryghost content-api.js that is used to establish the connection so this package dose not depend on `@tryghost/content-api` package.*
|
||||||
- If you are looking for a more Customizable option please check [astro-ghostcms-basetheme](https://github.com/MatthiesenXYZ/astro-ghostcms-basetheme)
|
- If you are looking for a more Customizable option please check [astro-ghostcms-basetheme](https://github.com/MatthiesenXYZ/astro-ghostcms-basetheme)
|
||||||
|
- This project is not setup for SSR in Integration mode. As such is will most likely not function properly in that mode. You will need to build your own project around the API or customize the *basetheme* linked above.
|
||||||
|
|
||||||
## Astro Integration Mode
|
## Astro Integration Mode
|
||||||
|
|
||||||
|
|
|
@ -1,8 +0,0 @@
|
||||||
import { defineConfig } from "astro/config";
|
|
||||||
import sitemap from "@astrojs/sitemap";
|
|
||||||
import GhostCMS from './index';
|
|
||||||
|
|
||||||
// https://astro.build/config
|
|
||||||
export default defineConfig({
|
|
||||||
integrations: [sitemap(), GhostCMS()],
|
|
||||||
});
|
|
14
index.ts
14
index.ts
|
@ -11,37 +11,37 @@ export default function GhostCMS(): AstroIntegration {
|
||||||
|
|
||||||
injectRoute({
|
injectRoute({
|
||||||
pattern: '/',
|
pattern: '/',
|
||||||
entrypoint: './src/routes/index.astro'
|
entrypoint: '@matthiesenxyz/astro-ghostcms/index.astro'
|
||||||
})
|
})
|
||||||
|
|
||||||
injectRoute({
|
injectRoute({
|
||||||
pattern: '/[slug]',
|
pattern: '/[slug]',
|
||||||
entrypoint: './src/routes/[slug].astro'
|
entrypoint: '@matthiesenxyz/astro-ghostcms/[slug].astro'
|
||||||
})
|
})
|
||||||
|
|
||||||
injectRoute({
|
injectRoute({
|
||||||
pattern: '/tags',
|
pattern: '/tags',
|
||||||
entrypoint: './src/routes/tags.astro'
|
entrypoint: '@matthiesenxyz/astro-ghostcms/tags.astro'
|
||||||
})
|
})
|
||||||
|
|
||||||
injectRoute({
|
injectRoute({
|
||||||
pattern: '/authors',
|
pattern: '/authors',
|
||||||
entrypoint: './src/routes/authors.astro'
|
entrypoint: '@matthiesenxyz/astro-ghostcms/authors.astro'
|
||||||
})
|
})
|
||||||
|
|
||||||
injectRoute({
|
injectRoute({
|
||||||
pattern: '/tag/[slug]',
|
pattern: '/tag/[slug]',
|
||||||
entrypoint: './src/routes/tag/[slug].astro'
|
entrypoint: '@matthiesenxyz/astro-ghostcms/tag/[slug].astro'
|
||||||
})
|
})
|
||||||
|
|
||||||
injectRoute({
|
injectRoute({
|
||||||
pattern: '/author/[slug]',
|
pattern: '/author/[slug]',
|
||||||
entrypoint: './src/routes/author/[slug].astro'
|
entrypoint: '@matthiesenxyz/astro-ghostcms/author/[slug].astro'
|
||||||
})
|
})
|
||||||
|
|
||||||
injectRoute({
|
injectRoute({
|
||||||
pattern: '/archives/[...page]',
|
pattern: '/archives/[...page]',
|
||||||
entrypoint: './src/routes/archives/[...page].astro'
|
entrypoint: '@matthiesenxyz/astro-ghostcms/archives/[...page].astro'
|
||||||
})
|
})
|
||||||
|
|
||||||
logger.info('Astro GhostCMS Plugin Loaded!')
|
logger.info('Astro GhostCMS Plugin Loaded!')
|
||||||
|
|
12
package.json
12
package.json
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"name": "@matthiesenxyz/astro-ghostcms",
|
"name": "@matthiesenxyz/astro-ghostcms",
|
||||||
"description": "Astro GhostCMS integration to allow easier importing of GhostCMS Content",
|
"description": "Astro GhostCMS integration to allow easier importing of GhostCMS Content",
|
||||||
"version": "2.0.0-dev.1",
|
"version": "2.0.0",
|
||||||
"author": "MatthiesenXYZ (https://matthiesen.xyz)",
|
"author": "MatthiesenXYZ (https://matthiesen.xyz)",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
|
@ -32,9 +32,17 @@
|
||||||
],
|
],
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"astro-component",
|
"astro-component",
|
||||||
|
"astro-integration",
|
||||||
"withastro",
|
"withastro",
|
||||||
|
"astro",
|
||||||
|
"blog",
|
||||||
|
"content",
|
||||||
|
"integration",
|
||||||
"ghost",
|
"ghost",
|
||||||
"ghostcms"
|
"ghostcms",
|
||||||
|
"ghostcms-theme",
|
||||||
|
"ghost-theme",
|
||||||
|
"astro-theme"
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "astro dev",
|
"dev": "astro dev",
|
||||||
|
|
Loading…
Reference in New Issue