Files
EMS-ESP32/interface/src/setupProxy.js
2021-04-01 17:49:43 +02:00

16 lines
393 B
JavaScript

const createProxyMiddleware = require('http-proxy-middleware');
module.exports = function (app) {
app.use(
'/rest/*',
createProxyMiddleware({
target: 'http://localhost:3080',
secure: false,
changeOrigin: true,
// pathRewrite: {
// '^/api/settings': '/api/app/settings'
// },
})
);
};