-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgatsby-config.ts
121 lines (117 loc) · 4.24 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
import type { GatsbyConfig } from 'gatsby'
import dotenv from 'dotenv'
if (process.env.ENVIRONMENT !== 'production') {
dotenv.config()
}
const config: GatsbyConfig = {
siteMetadata: {
title: `Soraride's Blog`,
description: 'そららいどの手作りブログ。技術系とか。製作物とか。',
author: 'soraride',
email: '[email protected]',
// If you didn't use the resolveSiteUrl option this needs to be set: for gatsby-plugin-sitemap
siteUrl: `https://sorarideblog.com`,
},
plugins: [
`gatsby-plugin-sitemap`,
'gatsby-plugin-sass',
`gatsby-plugin-react-helmet`,
`gatsby-plugin-image`,
`gatsby-transformer-sharp`,
`gatsby-plugin-sharp`,
`gatsby-plugin-twitter`,
{
resolve: 'gatsby-plugin-google-tagmanager',
options: {
id: 'GTM-NMZ8FCT',
includeInDevelopment: false,
defaultDataLayer: { platform: 'gatsby' },
// Specify optional GTM environment details.
// gtmAuth: 'YOUR_GOOGLE_TAGMANAGER_ENVIRONMENT_AUTH_STRING',
// gtmPreview: 'YOUR_GOOGLE_TAGMANAGER_ENVIRONMENT_PREVIEW_NAME',
// dataLayerName: 'YOUR_DATA_LAYER_NAME',
// Name of the event that is triggered
// on every Gatsby route change.
//
// Defaults to gatsby-route-change
// routeChangeEventName: 'YOUR_ROUTE_CHANGE_EVENT_NAME',
// Defaults to false
enableWebVitalsTracking: true,
},
},
{
resolve: 'gatsby-source-contentful',
options: {
spaceId: process.env.spaceId,
accessToken: process.env.accessToken,
enableTags: true,
},
},
// {
// resolve: `gatsby-source-filesystem`,
// options: {
// name: `images`,
// path: path.join(__dirname, `src`, `images`),
// ignore: [`**/.*`], // ignore files starting with a dot
// },
// },
{
resolve: `gatsby-transformer-remark`,
options: {
footnotes: true,
gfm: true,
plugins: [
`gatsby-remark-code-titles`,
`gatsby-remark-autolink-headers`,
// gatsby-remark-prismjs を使うときには
// gatsby-remark-autolink-headers よりも後ろに書く
{
resolve: `gatsby-remark-prismjs`,
options: {
classPrefix: 'language-',
inlineCodeMarker: null,
aliases: {},
showLineNumbers: false,
noInlineHighlight: false,
},
},
`gatsby-remark-check-links`,
{
resolve: 'gatsby-remark-external-links',
options: {
// デフォルトは _blank
target: '_blank',
// デフォルトは nofollow noopener noreferrer
rel: 'noopener noreferrer',
},
},
{
resolve: `gatsby-remark-link-card`,
options: {
//...
},
},
],
},
},
{
resolve: `gatsby-plugin-nprogress`,
options: {
// Setting a color is optional.
color: `tomato`,
// Disable the loading spinner.
showSpinner: false,
},
},
{
resolve: 'gatsby-plugin-robots-txt',
options: {
host: 'https://sorarideblog.com',
sitemap: 'https://sorarideblog.com/sitemap.xml',
policy: [{ userAgent: '*', allow: '/' }],
},
},
`gatsby-plugin-lodash`,
],
}
export default config