Initial commit
This commit is contained in:
commit
5a3bf52ebb
86 changed files with 2639 additions and 0 deletions
25
web/gatsby-config.js
Normal file
25
web/gatsby-config.js
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
// Load variables from `.env` as soon as possible
|
||||
require('dotenv').config({
|
||||
path: `.env.${process.env.NODE_ENV || 'development'}`
|
||||
})
|
||||
|
||||
const clientConfig = require('./client-config')
|
||||
const token = process.env.SANITY_READ_TOKEN
|
||||
|
||||
const isProd = process.env.NODE_ENV === 'production'
|
||||
|
||||
module.exports = {
|
||||
plugins: [
|
||||
'gatsby-plugin-postcss',
|
||||
'gatsby-plugin-react-helmet',
|
||||
{
|
||||
resolve: 'gatsby-source-sanity',
|
||||
options: {
|
||||
...clientConfig.sanity,
|
||||
token,
|
||||
watchMode: !isProd,
|
||||
overlayDrafts: !isProd && token
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue