如何为每个页面插入自定义的 JavaScript 代码? #4395
-
如何在 比如需要插入 Google Analytics 的 js。 |
Beta Was this translation helpful? Give feedback.
Answered by
FuckDoctors
Sep 4, 2024
Replies: 1 comment
-
可如下配置: // config.ts
export default defineUserConfig({
head: [
[
'script',
{
src: 'Google Analytics js',
},
],
]
}) |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
Mister-Hope
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
可如下配置: