How to use with Nuxt3? #176
-
I've been trying for the past week to figure this out. The documentation shows how to use the Vue Google analytics plugin, but for anything that provides a custom html component, I cannot seem to figure it out. I've found this answer which seems to get close, but no cigar. I've also found this answer but no joy there either. If someone can help me out I'm happy to submit a pull request with updated documentation for this project to explain how to use this great plugin for nuxt3 🙏 Thank you |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
May a bit late for the questioner, but I needed this recently and also had some trouble. You just need to create a .js or .ts file in the /plugins folder:
Then you only need to add the css at the nuxt.config.ts:
So you could just use it by the given name at any template:
May also notice that you have to use Hope this will still helps someone. |
Beta Was this translation helpful? Give feedback.
May a bit late for the questioner, but I needed this recently and also had some trouble.
So i want to provide my solution:
(Using nuxt@3.0.0 and vue-json-pretty@2.2.3)
You just need to create a .js or .ts file in the /plugins folder:
Then you only need to add the css at the nuxt.config.ts:
So you could just use it by the given name at any template: