-
Notifications
You must be signed in to change notification settings - Fork 16
/
gridsome.config.js
136 lines (134 loc) · 3.41 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
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
const tailwindcss = require("tailwindcss");
module.exports = {
siteName: "Gift Egwuenu",
siteUrl: "https://giftegwuenu.com",
siteDescription:
"Gift Egwuenu is a frontend developer and content creator. Her blog features content on frontend development, accessibility, and tech career advice.",
icon: {
favicon: "./src/favicon.png",
},
templates: {
Post: "/:title",
},
css: {
loaderOptions: {
postcss: {
plugins: [tailwindcss],
},
},
},
plugins: [
{
use: "@gridsome/source-filesystem",
options: {
typeName: "Post",
path: "content/posts/*.md",
remark: {
plugins: [
[
"gridsome-plugin-remark-prismjs-all",
{
showLineNumber: true,
highlightClassName: "gridsome-highlight",
codeTitleClassName: "gridsome-code-title",
classPrefix: "language-",
},
],
[
"@noxify/gridsome-plugin-remark-embed",
{
enabledProviders: [
"Youtube",
"Twitter",
"Gist",
"Codepen",
"Giphy",
"Spotify",
],
},
],
],
},
refs: {
// Creates a GraphQL collection from 'tags' in front-matter and adds a reference.
tags: {
typeName: "Tag",
create: true,
},
},
},
},
// {
// use: "@gridsome/plugin-google-analytics",
// options: {
// id: "UA-102896008-2",
// },
// },
{
use: 'gridsome-plugin-plausible-analytics',
options: {
dataDomain: 'giftegwuenu.dev',
outboundLinkTracking: false
}
},
{
use: "gridsome-plugin-rss",
options: {
contentTypeName: "Post",
latest: true,
feedOptions: {
title: "Gift Egwuenu",
description:
"A blog on frontend development, technical career and soft skills. Written by Gift Egwuenu",
feed_url: "https://giftegwuenu.com/rss.xml",
site_url: "https://giftegwuenu.com",
},
feedItemOptions: (node) => ({
title: node.title,
date: node.date,
url: "https://giftegwuenu.com" + node.path,
description: node.description,
custom_elements: [
{
"content:encoded": {
_cdata: node.content
}
}
]
}),
output: {
dir: "./static",
name: "rss.xml",
},
},
},
{
use: "@gridsome/plugin-sitemap",
options: {
cacheTime: 600000, // default
exclude: ["/exclude-me"],
config: {
"/*": {
changefreq: "weekly",
priority: 0.8,
}
},
},
},
{
use: "gridsome-plugin-monetization",
options: {
paymentPointer: process.env.GRIDSOME_PAYMENT_POINTER, // your payment pointer
global: true, // add monetization to every page; default: true
},
},
],
transformers: {
//Add markdown support to all file-system sources
remark: {
externalLinksTarget: "_blank",
externalLinksRel: ["nofollow", "noopener", "noreferrer"],
anchorClassName: "icon icon-link",
},
},
};