Files
sol-journal/gatsby-config.js
2022-08-31 19:42:32 -04:00

79 lines
1.8 KiB
JavaScript

require("dotenv").config();
module.exports = {
plugins: [
`gatsby-plugin-react-helmet`,
`gatsby-plugin-emotion`,
`gatsby-plugin-image`,
// create routes for client side routing
// provide fonts from Google fonts
// {
// resolve: `gatsby-plugin-prefetch-google-fonts`,
// options: {
// fonts: [
// {
// family: `Montserrat`,
// variants: [`400`, `700`],
// },
// ],
// },
// },
{
resolve: 'gatsby-plugin-web-font-loader',
options: {
google: {
families: ['Montserrat:400,700']
}
}
},
// plugins for PWA support
`gatsby-plugin-offline`,
{
resolve: `gatsby-plugin-manifest`,
options: {
name: `Sol Journal`,
short_name: `Sol Journal`,
start_url: `/`,
background_color: `#FFF`,
theme_color: `#FFF`,
display: `standalone`,
icon: `src/img/splash.png`,
cache_busting_mode: 'none'
},
},
`gatsby-plugin-sharp`,
{
resolve: `gatsby-source-filesystem`,
options: {
name: `images`,
path: `${__dirname}/src/img`,
},
},
// parse data from /src/data as Javascrip objects
`gatsby-transformer-sharp`,
`gatsby-transformer-json`,
{
resolve: `gatsby-source-filesystem`,
options: {
path: `./src/data/`,
},
},
// easier imports and exports by defining aliases
// for commonly used folders
{
resolve: "gatsby-plugin-module-resolver",
options: {
root: "./src",
aliases: {
components: "./components",
data: "./data",
img: "./img",
routes: "./routes",
styles: "./styles",
utils: "./utils",
},
},
},
],
}