Answers for "react setupProxy for orogin"

2

react setupproxy

const { createProxyMiddleware } = require('http-proxy-middleware');

module.exports = function(app) {
  app.use(
    '/api',
    createProxyMiddleware({
      target: 'http://localhost:5000',
      changeOrigin: true,
    })
  );
};
Posted by: Guest on February-24-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language