Skip to content

Commit

Permalink
added google analytics
Browse files Browse the repository at this point in the history
  • Loading branch information
akshatvg committed Jul 2, 2023
1 parent 5cf68bc commit 47c26d6
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/App.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,18 @@ function App() {
<ThemeProvider theme={theme}>
<BrowserRouter>
<ScrollToTop />
{/* Google Analytics */}
<script async src="https://www.googletagmanager.com/gtag/js?id=G-SPEMCLQ8VG" id="google-analytics" defer
strategy="afterInteractive"></script>
<script id="google-analytics-measurement" dangerouslySetInnerHTML={{
__html: `window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-SPEMCLQ8VG');`,
}}
defer
strategy="afterInteractive"
/>
<Routes>
<Route exact path="/" element={<Home />} />
<Route exact path="/home" element={<Home />} />
Expand Down

1 comment on commit 47c26d6

@vercel
Copy link

@vercel vercel bot commented on 47c26d6 Jul 2, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.