From 598df7350b8715180a749948a80eb980224eaa59 Mon Sep 17 00:00:00 2001 From: jffarge Date: Thu, 24 Jun 2021 17:39:55 +0200 Subject: [PATCH] docs: :bug: remove branch context + add amplitude option Signed-off-by: jffarge --- website/netlify.toml | 6 ------ website/src/theme/DocPage/index.js | 2 +- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/website/netlify.toml b/website/netlify.toml index 1345f8a3..6fccec8d 100644 --- a/website/netlify.toml +++ b/website/netlify.toml @@ -17,12 +17,6 @@ ignore = "git diff --quiet $CACHED_COMMIT_REF $COMMIT_REF . ../docs/" command = "yarn build:withoutAuth" -[context.docs-analytics] - # Do not build the site if there's no site-related changes since the last - # deploy. - ignore = "git diff --quiet $CACHED_COMMIT_REF $COMMIT_REF . ../docs/" - command = "yarn build" - [[redirects]] from = "/github-proxy/*" to = "https://github.com/:splat" diff --git a/website/src/theme/DocPage/index.js b/website/src/theme/DocPage/index.js index 83cdeb05..eae8cfc2 100644 --- a/website/src/theme/DocPage/index.js +++ b/website/src/theme/DocPage/index.js @@ -178,7 +178,7 @@ function DocPage(props) { var amplitudeInstance = amplitude.getInstance().init(process.env.REACT_APP_AMPLITUDE_ID, userAccessStatus?.login.toLowerCase(), { apiEndpoint: `${window.location.hostname}/t` }); - amplitude.getInstance().logEvent('Docs View', { "path": window.location.pathname }); + amplitude.getInstance().logEvent('Docs View', { "hostname": window.location.hostname, "path": window.location.pathname }); } }) }