add proxy api
This commit is contained in:
@@ -2,7 +2,7 @@ import {registrationStore} from '../store/store';
|
||||
|
||||
function prepareUrl(url) {
|
||||
if (url.startsWith('http')) return url;
|
||||
return `http://3.125.47.101/api/${url}`;
|
||||
return `${window.location.origin}/api/${url}`;
|
||||
}
|
||||
|
||||
function handleRequest(method, url, headers, attempts, token, body) {
|
||||
|
||||
@@ -38,6 +38,13 @@ module.exports = {
|
||||
client: {
|
||||
progress: true,
|
||||
},
|
||||
proxy: {
|
||||
'/api/**': {
|
||||
target: 'http://3.125.47.101',
|
||||
secure: false,
|
||||
changeOrigin: true
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
module: {
|
||||
|
||||
Reference in New Issue
Block a user