axios cors
dynamic host
Nuxt Axios Dynamic url
I manage to learn nuxt by using following tutorial https://scotch.io/tutorials/implementing-authentication-in-nuxtjs-app In the tutorial, it show that axios: { baseURL: 'http://127.0.0.1:3000/api' }, it is point to localhost, it is not a problem for my development, but when come to deployment, how do I change the URL based on the browser URL, if the system use in LAN, it will be 192.168.8.1:3000/api if the system use at outside, it will be example.com:3000/api On the other hand, Currently i using adonuxt (adonis + nuxt), both listen on same port (3000).
https://stackoverflow.com/questions/53851269/nuxt-axios-dynamic-url
base url is not working · Issue #134 · nuxt-community/axios-module
Dismiss GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together. Sign up You can't perform that action at this time. You signed in with another tab or window. You signed out in another tab or window.
https://github.com/nuxt-community/axios-module/issues/134
Introduction
Secure and easy Axios integration for Nuxt. Enjoy light and dark mode: Axios does not have an official logo yet, we decided to use the actual proposal submitted here: https://github.com/axios/axios/issues/2130
https://axios.nuxtjs.org/


Seonglae Cho