-
Notifications
You must be signed in to change notification settings - Fork 103
Closed
Labels
has fixA fix is PR'd or merged, but not yet releasedA fix is PR'd or merged, but not yet released
Description
I used baseURL in react but it doesn't affect the url
//axios-order.js
import axios from 'redaxios';
const instance = axios.create({
baseURL: 'http://something.com/api'
});
export default instance;
//login.js
import axios from './axios-order';
const url = '/auth/admin-login';
const authData = {
mobile: mobile,
password: password
};
axios.post(url, authData)
.then(response => JSON.parse(response.data))
.catch(error => {
console.log(error)
})
i receive this :
index.js:168 POST http://localhost:3000/auth/admin-login 404 (Not Found)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
has fixA fix is PR'd or merged, but not yet releasedA fix is PR'd or merged, but not yet released