How to read custom module options that defined in nuxt.config from module plugin ?
You can read module options in module.ts like this
But how to read module options in plugin ?
2 Replies
I think this may help https://nuxt.com/docs/guide/going-further/modules#exposing-options-to-runtime
you have to manually add those options to the nuxt config object
https://github.com/valgeirb/nuxt-fathom/blob/main/src/module.ts#L36-L40 just found an example here
GitHub
nuxt-fathom/src/module.ts at main · valgeirb/nuxt-fathom
Fathom Analytics integration for Nuxt. Contribute to valgeirb/nuxt-fathom development by creating an account on GitHub.