snipette-gridsome/gridsome.config.js
Hippo 9a0415d3ff Create view for Pages
GhostPost and GhostPage are copies of each other: they
conditionally render depending on whether the path matches a post
or page. The reason for this workaround is that, otherwise, the
router would show a 404 for non-matching posts even when a
matching page existed, since they both lie under the same path.
2019-12-24 13:38:50 +05:30

37 lines
794 B
JavaScript

module.exports = {
siteName: 'Snipette',
siteUrl: 'https://beta.snipettemag.com',
siteDescription: 'Your weekly dose of perspective, understandibility and fun',
titleTemplate: `%s - Snipette`,
mediaUrlFrom: 'https://snipette-ghost.herokuapp.com/content/images/',
mediaUrlTo: 'https://media.snipettemag.com/',
templates: {
GhostPost: '/:slug',
GhostPage: '/:slug',
GhostTag: '/tag/:slug',
GhostAuthor: '/author/:slug'
},
plugins: [
{
use: '@gridsome/plugin-google-analytics',
options: {
id: 'UA-XXXXXXXXX-X'
}
},
{
use: '@gridsome/source-ghost',
options: {
baseUrl: process.env.GHOST_API_URL,
contentKey: process.env.GHOST_CONTENT_KEY,
routes: {
post: '/:slug',
page: '/:slug',
author: '/author/:slug'
}
}
},
]
}