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

chore(analytics): adding analytics #344

Merged
merged 3 commits into from
Jan 12, 2024
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion .github/workflows/deploy-preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
- name: "Setup node@14"
uses: actions/setup-node@v2
with:
node-version: 16
node-version: 18

- name: "Install dependencies"
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
- name: "Setup node@14"
uses: actions/setup-node@v2
with:
node-version: 16
node-version: 18

- name: "Install dependencies"
run: |
Expand Down
2 changes: 2 additions & 0 deletions docs/.vuepress/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,8 @@ export default {
extraWatchFiles: ['.vuepress/config/**'],
head: [
['script', { src: '/hack.js', defer: "defer" }, ''],
['script', { src: 'https://www.googletagmanager.com/gtag/js?id=G-K9FLXQ2PYF', async: "true" }, ''],
['script', { src: '/analytics.js', async: "true" }, ''],
['link', { rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }],
['link', { rel: 'apple-touch-icon', sizes: '57x57', type: 'image/x-icon', href: '/apple-icon-57x57.png' }],
['link', { rel: 'apple-touch-icon', sizes: '60x60', type: 'image/x-icon', href: '/apple-icon-60x60.png' }],
Expand Down
5 changes: 5 additions & 0 deletions docs/.vuepress/public/analytics.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());

gtag('config', 'G-K9FLXQ2PYF');
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@
]
},
"scripts": {
"docs:dev": "vuepress dev docs",
"docs:build": "vuepress build docs",
"docs:deploy": "yarn docs:build && firebase deploy",
"docs:dev": "NODE_OPTIONS=--openssl-legacy-provider vuepress dev docs",
"docs:build": "NODE_OPTIONS=--openssl-legacy-provider vuepress build docs",
"docs:deploy": "NODE_OPTIONS=--openssl-legacy-provider yarn docs:build && firebase deploy",
"cspell": "cspell lint --no-summary --fail-fast --no-progress --no-must-find-files -c cspell.json docs/**/*.md ",
"md:lint": "markdownlint --config .markdownlintrc ./docs/**/*.md",
"md:fix": "markdownlint --fix -c .markdownlintrc ./docs/**/*.md",
Expand Down
Loading