forked from cossssmin/gridsome-starter-bleda
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathgridsome.config.js
106 lines (101 loc) · 2.35 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
96
97
98
99
100
101
102
103
104
105
106
module.exports = {
siteName: 'Dev Kimchi',
siteDescription: "Fermentation: Turning .NET, Web and Cloud into Something",
siteUrl: 'https://devkimchi.com',
titleTemplate: `%s | DevKimchi`,
icon: 'src/favicon.png',
transformers: {
remark: {
externalLinksTarget: '_blank',
externalLinksRel: ['nofollow', 'noopener', 'noreferrer'],
plugins: [
[ 'gridsome-plugin-remark-shiki', {
theme: 'min-light'
}
],
[ '@noxify/gridsome-plugin-remark-embed', {
'enabledProviders': [ 'Youtube', 'Twitter', 'Gist' ],
'Twitter': {
'hideMedia': false,
'theme': '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-54189949-1',
},
},
{
use: '@gridsome/plugin-sitemap',
options: {
cacheTime: 600000, // default
},
},
{
use: 'gridsome-plugin-rss',
options: {
contentTypeName: 'Post',
latest: true,
dateField: 'date',
feedOptions: {
title: 'Dev Kimchi',
feed_url: 'https://devkimchi.com/feed.xml',
site_url: 'https://devkimchi.com',
},
feedItemOptions: node => ({
title: node.title,
description: node.description,
url: 'https://devkimchi.com' + node.path,
author: node.author,
date: node.date,
}),
output: {
dir: './static',
name: 'feed.xml',
},
},
},
],
templates: {
Post: '/:year/:month/:day/:slug',
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
})
},
}