This repository has been archived by the owner on Feb 25, 2023. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 49
/
Copy pathgridsome.config.js
95 lines (90 loc) · 2.23 KB
/
gridsome.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
module.exports = {
siteName: 'A blog starter for Gridsome',
siteDescription: "Bleda is a blog starter kit for Gridsome, the Vue.js static site generator. It's inspired by Attila for Ghost, and styled with Tailwind CSS.",
siteUrl: 'https://gridsome-starter-bleda.netlify.com',
titleTemplate: `%s | Bleda`,
icon: 'src/favicon.png',
transformers: {
remark: {
externalLinksTarget: '_blank',
externalLinksRel: ['nofollow', 'noopener', 'noreferrer'],
plugins: [
['gridsome-plugin-remark-shiki', {
theme: 'min-light'
}]
]
}
},
plugins: [
{
use: '@gridsome/source-filesystem',
options: {
path: 'content/posts/**/*.md',
typeName: 'Post',
refs: {
tags: {
typeName: 'Tag',
create: true,
},
author: {
typeName: 'Author',
create: true,
},
},
},
},
{
use: '@gridsome/plugin-google-analytics',
options: {
id: 'UA-135446199-1',
},
},
{
use: '@gridsome/plugin-sitemap',
options: {
cacheTime: 600000, // default
},
},
{
use: 'gridsome-plugin-rss',
options: {
contentTypeName: 'Post',
feedOptions: {
title: 'Bleda, a Gridsome blog starter',
feed_url: 'https://gridsome-starter-bleda.netlify.com/feed.xml',
site_url: 'https://gridsome-starter-bleda.netlify.com',
},
feedItemOptions: node => ({
title: node.title,
description: node.description,
url: 'https://gridsome-starter-bleda.netlify.com' + node.path,
author: node.author,
date: node.date,
}),
output: {
dir: './static',
name: 'feed.xml',
},
},
},
],
templates: {
Post: '/:title',
Tag: '/tag/:id',
Author: '/author/:id',
},
chainWebpack: config => {
config.module
.rule('css')
.oneOf('normal')
.use('postcss-loader')
.tap(options => {
options.plugins.unshift(...[
require('postcss-import'),
require('postcss-nested'),
require('tailwindcss'),
])
return options
})
},
}