Skip to content

Commit b52f66b

Browse files
committed
feat: using Google Analytics
1 parent ae4674b commit b52f66b

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

docs/.vitepress/config.ts

+16-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,22 @@ export default defineConfig({
66
base: '/x-crawl/',
77

88
head: [
9-
['link', { rel: 'icon', type: 'image/svg+xml', href: '/x-crawl/logo.svg' }]
9+
['link', { rel: 'icon', type: 'image/svg+xml', href: '/x-crawl/logo.svg' }],
10+
[
11+
'script',
12+
{
13+
async: '',
14+
src: 'https://www.googletagmanager.com/gtag/js?id=G-8Y4QZJH6CX'
15+
}
16+
],
17+
[
18+
'script',
19+
{},
20+
`window.dataLayer = window.dataLayer || [];
21+
function gtag(){dataLayer.push(arguments);}
22+
gtag('js', new Date());
23+
gtag('config', 'G-8Y4QZJH6CX');`
24+
]
1025
],
1126

1227
cleanUrls: true,

0 commit comments

Comments
 (0)