Skip to content

Commit

Permalink
feat(plausible): Add plausible analytics.
Browse files Browse the repository at this point in the history
  • Loading branch information
aaronmussig committed Jan 30, 2023
1 parent f42e10a commit 31f5560
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 3 deletions.
14 changes: 13 additions & 1 deletion nuxt.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ export default {
iconfont: 'mdiSvg'
}
}], // https://typed-vuex.roe.dev
'nuxt-typed-vuex'],
'nuxt-typed-vuex',
'vue-plausible'
],

// Modules: https://go.nuxtjs.dev/config-modules
modules: [// https://go.nuxtjs.dev/axios
Expand Down Expand Up @@ -152,6 +154,16 @@ export default {
generate: {
fallback: 'error.html',
subFolders: false
},

plausible: { // Use as fallback if no runtime config is available at runtime
domain: process.env.PLAUSIBLE_DOMAIN
},
publicRuntimeConfig: {
plausible: {
domain: process.env.PLAUSIBLE_DOMAIN,
apiHost: process.env.PLAUSIBLE_API_HOST
}
}

}
34 changes: 32 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
"nuxt": "^2.15.8",
"nuxt-typed-vuex": "^0.3.1",
"vue-gtag": "^1.16.1",
"vue-plausible": "^1.3.2",
"vuetify": "^2.6.14"
},
"devDependencies": {
Expand Down

0 comments on commit 31f5560

Please sign in to comment.