Skip to content

Commit

Permalink
Remove analytics
Browse files Browse the repository at this point in the history
  • Loading branch information
antoine-okay committed May 23, 2023
1 parent 12f9a4d commit b9d42f2
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 54 deletions.
27 changes: 0 additions & 27 deletions components/app/AppHeader.vue
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
exact-active-class="text-primary-500"
>{{ lastRelease.name }}</NuxtLink>
<div class="flex items-center">
<a href="https://join.slack.com/t/eng-analytics/shared_invite/zt-1i8emziud-nmGDL~h2bNrZMyu9idzqNg" class="text-sm mb-1 text-gray-700 dark:text-gray-300 hover:text-primary-500 dark-hover:text-primary-500">Join our Slack</a>
<github-button
:class="{
'hidden lg:block': settings.layout !== 'single'
Expand All @@ -51,21 +50,6 @@
Star
</github-button>

<a
v-if="settings.twitter"
:href="`https://twitter.com/${settings.twitter}`"
target="_blank"
rel="noopener noreferrer"
title="Twitter"
name="Twitter"
class="text-gray-700 dark:text-gray-300 hover:text-primary-500 dark-hover:text-primary-500 ml-4 mb-1"
:class="{
'hidden lg:block': settings.layout !== 'single'
}"
>
<IconTwitter class="w-5 h-5" />
</a>

<button
v-if="settings.layout !== 'single'"
class="lg:hidden p-2 rounded-md text-gray-700 dark:text-gray-300 focus:outline-none -mr-2"
Expand Down Expand Up @@ -129,17 +113,6 @@ export default {
scrolled: 0
}
},
watch: {
async $route(to, from) {
if (process.env.eventsEndpoint) {
axios.post(process.env.eventsEndpoint, {
event: { page: 'Handbook', entity: `${to.path}`, action: 'Page View' },
event_properties: { path: this.$route.path, url: window.location.href, title: document.title },
user_agent: navigator.userAgent
});
}
}
},
computed: {
...mapGetters([
'settings',
Expand Down
14 changes: 1 addition & 13 deletions nuxt.config.js
Original file line number Diff line number Diff line change
@@ -1,20 +1,8 @@
import theme from '@nuxt/content-theme-docs'

export default theme({
buildModules: ['@nuxt/typescript-build', '@nuxtjs/google-analytics'],
router: {
base: '/handbook/'
},
i18n: {
baseUrl: '/handbook'
},
buildModules: ['@nuxt/typescript-build'],
build: {
transpile: [/^vue-github-button/]
},
env: {
eventsEndpoint: process.env.EVENTS_ENDPOINT
},
googleAnalytics: {
id: process.env.GOOGLE_ANALYTICS_ID
}
})
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
},
"devDependencies": {
"@nuxt/types": "^2.15.8",
"@nuxt/typescript-build": "^2.1.0",
"@nuxtjs/google-analytics": "^2.4.0"
"@nuxt/typescript-build": "^2.1.0"
}
}
12 changes: 0 additions & 12 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1590,13 +1590,6 @@
defu "^5.0.0"
lodash.template "^4.5.0"

"@nuxtjs/google-analytics@^2.4.0":
version "2.4.0"
resolved "https://registry.yarnpkg.com/@nuxtjs/google-analytics/-/google-analytics-2.4.0.tgz#3bb9f398a05cc23340d1f423f8d8653dc4114f46"
integrity sha512-rDQTwHIjyjVrx8GywHPuWykJ3jRFGaHl5Iqji/y8tQWUc0yGEeHxOoR0yimzxnTS1Ph2/PubQYpgnVeEPEdL/A==
dependencies:
vue-analytics "^5.22.1"

"@nuxtjs/[email protected]":
version "1.2.0"
resolved "https://registry.yarnpkg.com/@nuxtjs/google-fonts/-/google-fonts-1.2.0.tgz#b226683f2ccfdb1caab02729ff1c513062b9e868"
Expand Down Expand Up @@ -9923,11 +9916,6 @@ vm-browserify@^1.0.1:
resolved "https://registry.yarnpkg.com/vm-browserify/-/vm-browserify-1.1.2.tgz#78641c488b8e6ca91a75f511e7a3b32a86e5dda0"
integrity sha512-2ham8XPWTONajOR0ohOKOHXkm3+gaBmGut3SRuu75xLd/RRaY6vqgh8NBYYk7+RW3u5AtzPQZG8F10LHkl0lAQ==

vue-analytics@^5.22.1:
version "5.22.1"
resolved "https://registry.yarnpkg.com/vue-analytics/-/vue-analytics-5.22.1.tgz#9d6b32da56daee1b9dfb23a267b50349a03f710f"
integrity sha512-HPKQMN7gfcUqS5SxoO0VxqLRRSPkG1H1FqglsHccz6BatBatNtm/Vyy8brApktZxNCfnAkrSVDpxg3/FNDeOgQ==

vue-client-only@^2.0.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/vue-client-only/-/vue-client-only-2.1.0.tgz#1a67a47b8ecacfa86d75830173fffee3bf8a4ee3"
Expand Down

0 comments on commit b9d42f2

Please sign in to comment.