Browse Source

proxy / CORS

test1
Georg Spar 1 year ago
parent
commit
93be80d51d
  1. 3
      nuxt.config.js

3
nuxt.config.js

@ -50,11 +50,12 @@ export default {
axios: {
// Workaround to avoid enforcing hard-coded localhost:3000: https://github.com/nuxt-community/axios-module/issues/308
baseURL: '/',
browserBaseURL: '/',
proxy: true
},
proxy: {
'/api/v1/': { target: 'http://localhost:8081/', changeOrigin: true },
'/api/': { target: 'http://127.0.0.1:8081/', changeOrigin: true },
},
// Build Configuration: https://go.nuxtjs.dev/config-build

Loading…
Cancel
Save