File tree Expand file tree Collapse file tree 3 files changed +20
-18
lines changed Expand file tree Collapse file tree 3 files changed +20
-18
lines changed Original file line number Diff line number Diff line change @@ -2,9 +2,9 @@ import Script from "next/script"
22
33const GA = ( ) => {
44 return (
5- < >
5+ < div id = "ga" >
66 < Script async src = "https://www.googletagmanager.com/gtag/js?id=G-ZS8DH79JJ7" > </ Script >
7- < Script id = "ga" defer = { false } >
7+ < Script id = "google-analytics" >
88 { `
99 window.dataLayer = window.dataLayer || [];
1010 function gtag(){dataLayer.push(arguments);}
@@ -13,7 +13,7 @@ const GA = () => {
1313 gtag('config', 'G-ZS8DH79JJ7');
1414 ` }
1515 </ Script >
16- </ >
16+ </ div >
1717 )
1818}
1919
Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ import Container from "@mui/material/Container"
33import CssBaseline from "@mui/material/CssBaseline"
44import { ThemeProvider } from "@mui/material/styles"
55
6+ import GA from "@/lib/components/GA"
67import BusProvider from "@/lib/components/BusProvider/BusProvider"
78import Notification from "@/lib/components/Notification/Notification"
89import Header from "@/lib/components/Header/Header"
@@ -14,18 +15,21 @@ export default function App({ Component, pageProps }: AppProps) {
1415 const user = pageProps && pageProps . user
1516
1617 return (
17- < ThemeProvider theme = { theme } >
18- < CssBaseline />
19- < BusProvider >
20- < div className = "app-container" >
21- { ! embed && < Header title = "Link Flow" user = { user } /> }
22- < Container disableGutters maxWidth = "xl" >
23- < Component { ...pageProps } />
24- </ Container >
25- { ! embed && < Footer /> }
26- < Notification />
27- </ div >
28- </ BusProvider >
29- </ ThemeProvider >
18+ < >
19+ < ThemeProvider theme = { theme } >
20+ < CssBaseline />
21+ < BusProvider >
22+ < div className = "app-container" >
23+ { ! embed && < Header title = "Link Flow" user = { user } /> }
24+ < Container disableGutters maxWidth = "xl" >
25+ < Component { ...pageProps } />
26+ </ Container >
27+ { ! embed && < Footer /> }
28+ < Notification />
29+ </ div >
30+ </ BusProvider >
31+ </ ThemeProvider >
32+ < GA />
33+ </ >
3034 )
3135}
Original file line number Diff line number Diff line change 11import { Html , Head , Main , NextScript } from "next/document"
2- import GA from "@/lib/components/GA"
32
43export default function Document ( ) {
54 return (
@@ -9,7 +8,6 @@ export default function Document() {
98 < meta name = "viewport" content = "width=device-width, initial-scale=1" />
109 < link rel = "icon" href = "/favicon.ico" />
1110 < meta name = "theme-color" content = "#202124" />
12- < GA />
1311 </ Head >
1412 < body >
1513 < Main />
You can’t perform that action at this time.
0 commit comments