Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(nx-dev): add apollo.io tracking script to _app.tsx #22339

Merged
merged 1 commit into from
Mar 15, 2024
Merged
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
10 changes: 10 additions & 0 deletions nx-dev/nx-dev/pages/_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ export default function CustomApp({
Skip to content
</Link>
<Component {...pageProps} />

{/* Global Site Tag (gtag.js) - Google Analytics */}
<Script
id="gtag-script-dependency"
Expand All @@ -96,6 +97,15 @@ export default function CustomApp({
`,
}}
/>
{/* Apollo.io Embed Code */}
<Script
type="text/javascript"
id="apollo-script-loader"
strategy="afterInteractive"
dangerouslySetInnerHTML={{
__html: `function initApollo(){var n=Math.random().toString(36).substring(7),o=document.createElement("script"); o.src="https://assets.apollo.io/micro/website-tracker/tracker.iife.js?nocache="+n,o.async=!0,o.defer=!0,o.onload=function(){window.trackingFunctions.onLoad({appId:"65e1db2f1976f30300fd8b26"})},document.head.appendChild(o)}initApollo();`,
}}
/>
{/* HubSpot Analytics */}
<Script
id="hs-script-loader"
Expand Down