We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4f003e0 commit b1b31a9Copy full SHA for b1b31a9
setupProxy.js
@@ -0,0 +1,14 @@
1
+const proxy = require('http-proxy-middleware')
2
+// this proxy code allows the use of .netlify/function in both development and production
3
+module.exports = function(app){
4
+ app.use(
5
+ proxy(
6
+ "/.netlify/functions", {
7
+ target: "http://localhost:9000",
8
+ pathRewrite: {
9
+ "^/\\.netlify/functions": ""
10
+ }
11
12
+ )
13
14
+}
0 commit comments