Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ WC_PROJECT_ID= ""
SOCKET_API_KEY= ""
PEANUT_API_KEY= ""
OPTI_GOERLI_RPC_URL= ""
GOERLI_RPC_URL= ""
GOERLI_RPC_URL= ""
GA_KEY= ""
1 change: 1 addition & 0 deletions next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ const nextConfig = {
PEANUT_API_KEY: process.env.PEANUT_API_KEY,
OPTI_GOERLI_RPC_URL: process.env.OPTI_GOERLI_RPC_URL,
GOERLI_RPC_URL: process.env.GOERLI_RPC_URL,
GA_KEY: process.env.GA_KEY,
},
};

Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"react": "18.2.0",
"react-dom": "18.2.0",
"react-fast-marquee": "^1.6.0",
"react-ga4": "^2.1.0",
"react-hook-form": "^7.42.1",
"react-hot-toast": "^2.4.1",
"react-qr-code": "^2.0.11",
Expand Down
2 changes: 2 additions & 0 deletions src/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import { WagmiConfig } from "wagmi";
import * as config from "@/config";
import { Store } from "@/store/store";
import { useState, useEffect } from "react";
import ReactGA from "react-ga4";

const inter = Inter({ subsets: ["latin"] });

Expand All @@ -20,6 +21,7 @@ export default function RootLayout({
//this useEffect is needed to prevent hydration error when autoConnect in wagmiConfig is true
useEffect(() => {
setReady(true);
ReactGA.initialize(process.env.GA_KEY ?? "");
}, []);

return (
Expand Down
5 changes: 5 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5972,6 +5972,11 @@ react-fast-marquee@^1.6.0:
resolved "https://registry.yarnpkg.com/react-fast-marquee/-/react-fast-marquee-1.6.0.tgz#3749a9d0f522234e1e3ab776f105cd0accd76a4a"
integrity sha512-jtuwT9SNjrqxnE7lGZ8mTL1I8Q4+9G4aBta2p+y2Pa3SjR17QROblwrLICyM8rbjQFHgHawTHcaH9HvoVO2NOA==

react-ga4@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/react-ga4/-/react-ga4-2.1.0.tgz#56601f59d95c08466ebd6edfbf8dede55c4678f9"
integrity sha512-ZKS7PGNFqqMd3PJ6+C2Jtz/o1iU9ggiy8Y8nUeksgVuvNISbmrQtJiZNvC/TjDsqD0QlU5Wkgs7i+w9+OjHhhQ==

react-hook-form@^7.42.1:
version "7.45.4"
resolved "https://registry.yarnpkg.com/react-hook-form/-/react-hook-form-7.45.4.tgz#73d228b704026ae95d7e5f7b207a681b173ec62a"
Expand Down