Skip to content

Commit

Permalink
Update gtat config
Browse files Browse the repository at this point in the history
  • Loading branch information
maks-oleksyuk committed Oct 20, 2024
1 parent b10b372 commit 9fb25c8
Show file tree
Hide file tree
Showing 7 changed files with 322 additions and 317 deletions.
1 change: 1 addition & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
VITE_GTAG='G-xxxxxxxxxx'
2 changes: 2 additions & 0 deletions .github/workflows/cd-gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ jobs:

- name: ⚡️ Build site with VitePress
run: pnpm notes:build
env:
VITE_GTAG: ${{ secrets.VITE_GTAG }}

- name: 📤 Upload artifact
uses: actions/upload-pages-artifact@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci-gh-pages.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: 🔁 CI | ⚡️ VitePress
name: 🔄 CI | ⚡️ VitePress

on:
push:
Expand Down
1 change: 1 addition & 0 deletions .vitepress/config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ export default defineConfig({
},
},
vite: {
envDir: './../',
ssr: {
noExternal: ['@nolebase/vitepress-plugin-enhanced-readabilities'],
},
Expand Down
2 changes: 1 addition & 1 deletion .vitepress/theme/index.mts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@ export default {
enhanceApp({ app }) {
enhanceAppWithTabs(app);
vitepressBackToTop({ threshold: 300 });
googleAnalytics({ id: 'G-L5YJQ5Q3TD' });
googleAnalytics({ id: import.meta.env.GTAG });
},
};
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,16 @@
"lint:format:fix": "prettier -wl ./ '!pnpm-lock.yaml' --cache"
},
"devDependencies": {
"@nolebase/vitepress-plugin-enhanced-readabilities": "2.5.0",
"@nolebase/vitepress-plugin-enhanced-readabilities": "2.6.1",
"prettier": "^3.3.3",
"vitepress": "^1.3.4",
"vitepress": "^1.4.1",
"vitepress-plugin-back-to-top": "^1.0.1",
"vitepress-plugin-google-analytics": "^1.0.2",
"vitepress-plugin-tabs": "^0.5.0",
"vitepress-sidebar": "^1.27.1",
"vue": "^3.5.10"
"vue": "^3.5.12"
},
"packageManager": "pnpm@9.11.0",
"packageManager": "pnpm@9.12.2",
"engines": {
"pnpm": ">=9",
"node": ">=20"
Expand Down
623 changes: 312 additions & 311 deletions pnpm-lock.yaml

Large diffs are not rendered by default.

0 comments on commit 9fb25c8

Please sign in to comment.