-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathgatsby-config.js
41 lines (40 loc) · 1.27 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
require('dotenv').config();
module.exports = {
siteMetadata: {
title: `Dashboard`,
author: `Ondřej Chrastina`,
description: `Showcase of Kentico Kontent Intranet admin UI using Material design and Gatsby.`,
siteUrl: `https://kontent-sample-app-gatsby-intranet.netlify.com/`,
social: {
twitter: `ChrastinaOndrej`,
},
},
plugins: [
{
resolve: `gatsby-plugin-material-ui`,
},
{
resolve: '@kentico/gatsby-source-kontent',
options: {
projectId: process.env.KONTENT_PROJECT_ID, // Fill in your Project ID
// if false used authorization key for secured API
usePreviewUrl:
process.env.KONTENT_PREVIEW_ENABLED && process.env.KONTENT_PREVIEW_ENABLED.toLowerCase() === 'true',
authorizationKey:
process.env.KONTENT_PREVIEW_ENABLED && process.env.KONTENT_PREVIEW_ENABLED.toLowerCase() === 'true'
? process.env.KONTENT_PREVIEW_KEY
: undefined,
languageCodenames: process.env.KONTENT_LANGUAGE_CODENAMES.split(',').map(lang => lang.trim()),
},
},
{
resolve: `gatsby-plugin-i18n`,
options: {
langKeyDefault: 'en',
langKeyForNull: 'en',
prefixDefault: false,
useLangKeyLayout: false,
},
},
],
};