Skip to content

Commit

Permalink
feat: Replace GA by GTAG (pancakeswap#54)
Browse files Browse the repository at this point in the history
  • Loading branch information
RabbitDoge authored Nov 2, 2020
1 parent 71222c1 commit 062f8b0
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 44 deletions.
3 changes: 2 additions & 1 deletion .env.development
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
REACT_APP_RPC_URL = "https://bsc-dataseed.binance.org"
REACT_APP_CHAIN_ID = "56"
REACT_APP_CHAIN_ID = "56"
REACT_APP_GTAG = "GTM-PXLD3XW"
1 change: 1 addition & 0 deletions .env.production
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
REACT_APP_RPC_URL = "https://bsc-dataseed.binance.org"
REACT_APP_CHAIN_ID = "56"
REACT_APP_GTAG = "GTM-TLF66T4"
80 changes: 37 additions & 43 deletions public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,38 @@
<html lang="en">
<head>
<meta charset="utf-8" />
<link rel="shortcut icon" href="%PUBLIC_URL%/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<meta name="description" content="Flip CAKE, collect SYRUP and stake them with PancakeSwap, the best decentralized exchange on Binance Smart Chain" />
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo512.png">
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<meta name="viewport" content="initial-scale=1, maximum-scale=3, minimum-scale=1, user-scalable=no">
<!-- GTAG -->
<script>
;(function (w, d, s, l, i) {
w[l] = w[l] || []
w[l].push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' })
var f = d.getElementsByTagName(s)[0],
j = d.createElement(s),
dl = l != 'dataLayer' ? '&l=' + l : ''
j.async = true
j.src = 'https://www.googletagmanager.com/gtm.js?id=' + i + dl
f.parentNode.insertBefore(j, f)
})(window, document, 'script', 'dataLayer', '%REACT_APP_GTAG%')
</script>
<!-- Links -->
<link
href="https://fonts.googleapis.com/css2?family=Kaushan+Script&family=Noto+Sans:wght@400;700&family=Reem+Kufi&family=Roboto+Mono:wght@400;700&display=swap"
rel="stylesheet"
/>
<link rel="shortcut icon" href="%PUBLIC_URL%/favicon.ico" />
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo.png" />
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<!-- Meta -->
<title>PancakeSwap</title>
<meta
name="description"
content="Flip CAKE, collect SYRUP and stake them with PancakeSwap, the best decentralized exchange on Binance Smart Chain"
/>
<meta
name="viewport"
content="width=device-width, initial-scale=1, maximum-scale=3, minimum-scale=1, user-scalable=no"
/>
<meta name="theme-color" content="#000000" />
<meta name="twitter:image" content="https://pancakeswap.finance/hero.png" />
<meta
name="twitter:description"
Expand All @@ -27,41 +44,18 @@
name="twitter:title"
content="🥞 PancakeSwap - A next evolution DeFi exchange on Binance Smart Chan (BSC)"
/>
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-172345269-2"></script>
<script async src="https://www.googletagmanager.com/gtag/js?id=G-334KNG3DMQ"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());

gtag('config', 'UA-172345269-2');
gtag('config', 'G-334KNG3DMQ');
</script>

<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.
Unlike "/favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>PancakeSwap</title>
</head>
<body>
<!-- GTAG (noscript) -->
<noscript>
<iframe
src="https://www.googletagmanager.com/ns.html?id=%REACT_APP_GTAG%"
height="0"
width="0"
style="display: none; visibility: hidden"
></iframe>
</noscript>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<!--
This HTML file is a template.
If you open it directly in the browser, you will see an empty page.
You can add webfonts, meta tags, or analytics to this file.
The build step will place the bundled scripts into the <body> tag.
To begin the development, run `npm start` or `yarn start`.
To create a production bundle, use `npm run build` or `yarn build`.
-->
</body>
</html>

0 comments on commit 062f8b0

Please sign in to comment.