Closed srbarba closed 3 years ago
Proxy module is configured in buildtime, so you can not use env variables expecting to change on runtime.
Nuxt has runtime config support since v2.13: https://nuxtjs.org/blog/moving-from-nuxtjs-dotenv-to-runtime-config
Axios module already use runtime config: https://github.com/nuxt-community/axios-module/blob/master/lib/module.js#L14
I suggest to do it the way axios module do it to allow proxy module works with runtime config.
What problem does this feature solve?
Proxy module is configured in buildtime, so you can not use env variables expecting to change on runtime.
What does the proposed changes look like?
Nuxt has runtime config support since v2.13: https://nuxtjs.org/blog/moving-from-nuxtjs-dotenv-to-runtime-config
Axios module already use runtime config: https://github.com/nuxt-community/axios-module/blob/master/lib/module.js#L14
I suggest to do it the way axios module do it to allow proxy module works with runtime config.