-
Notifications
You must be signed in to change notification settings - Fork 0
/
gatsby-config.js
134 lines (134 loc) · 3.75 KB
/
gatsby-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
module.exports = {
siteMetadata: {
title: `Ken's Blog`,
description: `Programming blog created with Gatsby`,
author: `Ken Cheung`,
},
plugins: [
{
resolve: "gatsby-plugin-firebase",
options: {
credentials: {
apiKey: "AIzaSyA8Nv1n-y_I4twumwIMNEi1wVb7kebt2y4",
authDomain: "personal-blog-7bf0b.firebaseapp.com",
projectId: "personal-blog-7bf0b",
storageBucket: "personal-blog-7bf0b.appspot.com",
messagingSenderId: "214552775085",
appId: "1:214552775085:web:83d0866cc55f8af9dab924",
measurementId: "G-HC9V7THJZL",
},
},
},
"gatsby-plugin-image",
{
resolve: `gatsby-source-filesystem`,
options: {
name: `blogs`,
path: `${__dirname}/content/blogs`,
},
},
{
resolve: `gatsby-source-filesystem`,
options: {
name: `projects`,
path: `${__dirname}/content/projects`,
},
},
// include our netlify cms assets
{
resolve: `gatsby-source-filesystem`,
options: {
name: `assets`,
path: `${__dirname}/content/assets`,
},
},
// set up *.md files processing
{
resolve: `gatsby-plugin-mdx`,
options: {
extensions: [".mdx", ".md"],
gatsbyRemarkPlugins: [
// prepare images for gatsby
{
resolve: `gatsby-remark-images`,
options: {
maxWidth: 960,
},
},
// display embedded content (f.e. youtube videos)
{
resolve: `gatsby-remark-responsive-iframe`,
options: {
wrapperStyle: `margin-bottom: 1.0725rem`,
},
},
// display embedded code fragments
{
resolve: `gatsby-remark-vscode`,
},
// copy files (i.e. images) to public folder during build process
// for production
{
resolve: `gatsby-remark-copy-linked-files`,
},
// improve syntax
{
resolve: `gatsby-remark-smartypants`,
},
],
plugins: [`gatsby-remark-images`],
},
},
`gatsby-plugin-netlify-cms`,
`gatsby-plugin-react-helmet`,
{
resolve: `gatsby-source-filesystem`,
options: {
name: `images`,
path: `${__dirname}/src/images`,
},
},
`gatsby-transformer-sharp`,
`gatsby-plugin-sharp`,
{
resolve: `gatsby-plugin-manifest`,
options: {
name: `Ken's Blog`,
short_name: `ken`,
start_url: `/`,
background_color: `#FFFFFF`,
theme_color: `#FFFFFF`,
display: `minimal-ui`,
icon: `src/images/favicon.png`, // This path is relative to the root of the site.
},
},
{
resolve: `gatsby-source-filesystem`,
options: {
path: `${__dirname}/locales`,
name: `locale`,
},
},
{
resolve: `gatsby-plugin-react-i18next`,
options: {
localeJsonSourceName: `locale`, // name given to `gatsby-source-filesystem` plugin.
languages: [`en`, `jp`],
// if you are using Helmet, you must include siteUrl, and make sure you add http:https
siteUrl: `https://wasd0109ken.engineer/`,
// you can pass any i18next options
// pass following options to allow message content as a key
i18nextOptions: {
interpolation: {
escapeValue: false, // not needed for react as it escapes by default
},
keySeparator: ".",
nsSeparator: false,
},
},
},
// this (optional) plugin enables Progressive Web App + Offline functionality
// To learn more, visit: https://gatsby.dev/offline
// `gatsby-plugin-offline`,
],
}