From aee7be6a198a7c6345bcf2f037979bc10cd883bc Mon Sep 17 00:00:00 2001 From: Param Harrison Date: Sun, 24 May 2020 21:12:09 +0300 Subject: [PATCH] feat: Measuring performance audit using Lighthouse --- gatsby-browser.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/gatsby-browser.js b/gatsby-browser.js index 874bafa..94cae91 100644 --- a/gatsby-browser.js +++ b/gatsby-browser.js @@ -6,15 +6,19 @@ // You can delete this file if you're not using it -require("dotenv").config(); - import React from "react"; import { Elements } from "@stripe/react-stripe-js"; import { loadStripe } from "@stripe/stripe-js"; import CartProvider from "./src/context/cart"; -const stripePromise = loadStripe(`${process.env.GATSBY_STRIPE_KEY}`); +const stripePromise = loadStripe( + `${ + process.env.GATSBY_STRIPE_KEY + ? process.env.GATSBY_STRIPE_KEY + : "pk_test_FqfOKoybWF1MEQNRNbk5GWuw00Qgtn3SLM" + }` +); export const wrapRootElement = ({ element }) => (