text: require(`dotenv`).config()
  
  const googleAnalyticsTrackingId = process.env.GOOGLE_ANALYTICS_ID
  const shouldAnalyseBundle = process.env.ANALYSE_BUNDLE
  
  module.exports = {
    siteMetadata: {
      siteTitleAlt: `Jodie - Gatsby Starter Portfolio`,
    },
    plugins: [
      {
        resolve: `@lekoarts/gatsby-theme-jodie`,
        // See the theme's README for all available options
        options: {
          navigation: [
            { name: `Projects`, slug: `/projects` },
            { name: `Art`, slug: `/art` },
            { name: `About`, slug: `/about` },
          ],
        },
      },
      googleAnalyticsTrackingId && {
        resolve: `gatsby-plugin-google-analytics`,
        options: {
          trackingId: process.env.GOOGLE_ANALYTICS_ID,
        },
      },
      {
        resolve: `gatsby-omni-font-loader`,
        options: {
          enableListener: true,
          preconnect: [`https://fonts.gstatic.com`],
          interval: 300,
          timeout: 30000,
          // If you plan on changing the font you'll also need to adjust the Theme UI config to edit the CSS
          // See: https://github.com/LekoArts/gatsby-themes/tree/master/examples/jodie#changing-your-fonts
          web: [
            {
              name: `Work Sans`,
              file: `https://fonts.googleapis.com/css2?family=Work+Sans:wght@400..700&display=swap`,
            },
          ],
        },
      },
      `gatsby-plugin-sitemap`,
      {
        resolve: `gatsby-plugin-manifest`,
        options: {
          name: `jodie - @lekoarts/gatsby-theme-jodie`,
          short_name: `jodie`,
          description: `Image-heavy photography portfolio with colorful accents & customizable pages. Includes adaptive image grids powered by CSS grid and automatic image integration into projects.`,
          start_url: `/`,
          background_color: `#ffffff`,
          theme_color: `#b75e09`,
          display: `standalone`,
          icons: [
            {
              src: `/android-chrome-192x192.png`,
              sizes: `192x192`,
              type: `image/png`,
            },
            {
              src: `/android-chrome-512x512.png`,
              sizes: `512x512`,
              type: `image/png`,
            },
          ],
        },
      },
      `gatsby-plugin-offline`,
      `gatsby-plugin-gatsby-cloud`,
      `gatsby-plugin-netlify`,
      shouldAnalyseBundle && {
        resolve: `gatsby-plugin-webpack-bundle-analyser-v2`,
        options: {
          analyzerMode: `static`,
          reportFilename: `_bundle.html`,
          openAnalyzer: false,
        },
      },
    ].filter(Boolean),
  }
  