forked from developmentseed/aep
-
Notifications
You must be signed in to change notification settings - Fork 0
/
gatsby-config.js
93 lines (91 loc) · 2.33 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
const contentTypes = ['study', 'page'];
const siteUrl = process.env.SITE_URL || 'http://localhost:9000';
module.exports = {
flags: {
LAZY_IMAGES: true,
PARALLEL_SOURCING: true,
PRESERVE_WEBPACK_CACHE: true
},
siteMetadata: {
title: `Africa Electrification Platform`,
shortTitle: `AEP`,
author: {
name: `ESMAP / World Bank Group`
},
description: `Explore electrification planning activities in the Africa Region, interact with country data and explore different scenario results. The program is funded by ESMAP at the World Bank.`,
siteUrl,
social: {
twitter: ''
},
mapConfig: {
basemap: 'mapbox://styles/derilinx/ck3yqjovg4dpn1crwajrc9ajr',
mbToken:
'pk.eyJ1IjoiZGVyaWxpbngiLCJhIjoiY2szeTlzbWo2MDV6eDNlcDMxM3dzZXBieiJ9.zPf1iiFilYYwyx6ETNj_8w',
topLayer: 'admin-2-boundaries-bg'
}
},
plugins: [
'gatsby-optional-chaining',
`gatsby-plugin-react-helmet`,
`gatsby-plugin-styled-components`,
{
resolve: `gatsby-source-filesystem`,
options: {
path: `${__dirname}/content/icons`,
name: `icons`
}
},
...contentTypes.reduce(
(acc, type) => [
...acc,
// A content type is comprised of 2 directories: posts and images.
{
resolve: `gatsby-source-filesystem`,
options: {
path: `${__dirname}/content/${type}/posts`,
name: type
}
},
{
resolve: `gatsby-source-filesystem`,
options: {
path: `${__dirname}/content/${type}/media`,
name: `${type}-media`
}
}
],
[]
),
{
resolve: `gatsby-transformer-remark`,
options: {
plugins: [
{
resolve: `gatsby-remark-images`,
options: {
linkImagesToOriginal: false,
showCaptions: ['title'],
maxWidth: 1280
}
}
]
}
},
{
resolve: 'gatsby-transformer-yaml-full',
options: {
plugins: [
'gatsby-yaml-full-markdown' // Enable !markdown tags
]
}
},
`gatsby-transformer-sharp`,
`gatsby-plugin-sharp`
// {
// resolve: `gatsby-plugin-google-analytics`,
// options: {
// trackingId: ''
// }
// }
]
};