-
Notifications
You must be signed in to change notification settings - Fork 1
/
gatsby-config.ts
executable file
·197 lines (196 loc) · 4.63 KB
/
gatsby-config.ts
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
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
const siteKeywords = [
"博客",
"Jctaoo",
"个人主页",
"个人介绍",
"生活日常",
"技术",
"分享",
"开发",
"产品",
"设计",
"故事",
"Tao Juncheng",
];
export default {
siteMetadata: {
copyright: {
author: "jctaoo",
creativeCommons: "byNcSa"
},
config: {
lang: "zh",
host: "https://stella-demo-site.vercel.app/",
siteName: "Jctaoo.",
homeLargeTitle: "Jctaoo.",
experiment: {
downloadWebPicture: {
enable: true,
excludeUrlRegx: ["juejin"],
},
},
},
bannerText: "Stella Demo Site",
routeConfigurations: {
about: {
title: "关于",
},
passages: {
title: "文章",
},
snippets: {
title: "片段",
},
},
pageDescription: {
home: {
title: "主页",
keywords: siteKeywords,
description: "Jctaoo的个人网站",
largeImage: undefined,
largeImageAlt: undefined,
},
passages: {
title: "文章列表",
keywords: [...siteKeywords, "文章列表"],
description: "所有发布的文章列表",
largeImage: undefined,
largeImageAlt: undefined,
},
snippets: {
title: "片段列表",
keywords: [...siteKeywords, "片段列表", "vlog"],
description: "所有发布的片段列表, 记录代码与日常片段",
largeImage: undefined,
largeImageAlt: undefined,
},
about: {
title: "关于",
keywords: [...siteKeywords, "关于", "简介", "说明"],
description: "关于Jctaoo的个人网站",
largeImage: undefined,
largeImageAlt: undefined,
},
},
medias: [
// !
{
identifier: "1",
iconName: "bilibili",
title: "bilibili",
link: undefined,
imageName: undefined,
},
{
identifier: "2",
iconName: "github",
title: "github",
link: "https://github.com/jctaoo",
imageName: "github_qr_code.png",
},
{
identifier: "3",
iconName: "mail",
title: "mail",
link: "mailto:[email protected]",
imageName: undefined,
},
{
identifier: "4",
iconName: "twitter",
title: "twitter",
link: undefined,
imageName: undefined,
},
{
identifier: "5",
iconName: "wechat",
title: "wechat",
link: undefined,
imageName: undefined,
},
],
},
flags: {
PRESERVE_FILE_DOWNLOAD_CACHE: true,
PRESERVE_WEBPACK_CACHE: true,
FAST_DEV: true,
PARALLEL_SOURCING: true,
},
plugins: [
"gatsby-plugin-antd",
{
resolve: `gatsby-plugin-sass`,
options: {
implementation: require("sass"),
},
},
{
resolve: `gatsby-source-filesystem`,
options: {
name: `content`,
path: `${__dirname}/content/`,
},
},
{
resolve: `gatsby-plugin-sharp`,
options: {
formats: ["auto", "webp", "avif"],
defaults: {},
placeholder: `dominantColor`, // or BLURRED
width: 625,
failOnError: true,
base64Width: 20, // TODO:
forceBase64Format: `png`, // valid formats: png,jpg,webp
useMozJpeg: process.env.GATSBY_JPEG_ENCODER === `MOZJPEG`,
stripMetadata: true,
jpegProgressive: true,
defaultQuality: 50,
},
},
"gatsby-transformer-sharp",
"gatsby-plugin-image",
{
resolve: `gatsby-transformer-remark`,
options: {
footnotes: true,
gfm: true,
plugins: [
{
resolve: `gatsby-remark-images`,
options: {
maxWidth: 512,
linkImagesToOriginal: false,
},
},
{
resolve: `gatsby-remark-prismjs`,
options: {
classPrefix: "language-",
inlineCodeMarker: null,
aliases: {},
showLineNumbers: true,
noInlineHighlight: false,
prompt: {
user: "root",
host: "localhost",
global: false,
},
escapeEntities: {},
},
},
{
resolve: `gatsby-remark-katex`,
options: {
// Add any KaTeX options from https://github.com/KaTeX/KaTeX/blob/master/docs/options.md here
strict: `ignore`
}
}
],
},
},
"gatsby-plugin-typescript",
"gatsby-plugin-react-helmet",
"gatsby-plugin-offline",
],
};