Integration with Docusaurus
onattech opened this issue · 1 comments
onattech commented
Is there a way to integrate vercel analytics with Docusaurus?
tobiaslins commented
Hey!
I think there are two ways you could achieve this using Docusaurus.
- Adding a script tag
Add our tracking script todocusaurus.config.js
: https://docusaurus.io/docs/api/docusaurus-config#scripts
scripts: [
{
src: '/_vercel/insights/script.js',
defer: true,
},
],
Swizzling
your theme https://docusaurus.io/docs/swizzling#wrapper-your-site-with-root
There might be other ways to add it but I am not too familiar with docusaurus.
I hope that helps