Skip to content

Commit

Permalink
Correct proxy usage docs (#7368)
Browse files Browse the repository at this point in the history
  • Loading branch information
szabolcs-szilagyi authored and iansu committed Aug 19, 2019
1 parent 24780bb commit fbb3b03
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion docusaurus/docs/proxying-api-requests-in-development.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,10 @@ You can now register proxies as you wish! Here's an example using the above `htt
const proxy = require('http-proxy-middleware');

module.exports = function(app) {
app.use(proxy('/api', { target: 'http://localhost:5000/' }));
app.use('/api', proxy({
target: 'http://localhost:5000',
changeOrigin: true,
}));
};
```

Expand Down

0 comments on commit fbb3b03

Please sign in to comment.