diff --git a/package.json b/package.json index 4e0f367..7468e74 100644 --- a/package.json +++ b/package.json @@ -9,14 +9,23 @@ "react-scripts": "1.1.4" }, "scripts": { - "start": "react-scripts start", "bootstrap": "node ./init-faunadb.js", - "buildFunctions": "netlify-lambda build functions -c ./webpack.config.js", + "start": "concurrently \"react-scripts start\" \"npm run startServer\"", + "startServer": "netlify-lambda serve functions -c ./webpack.config.js", "build": "npm run buildFunctions && react-scripts build", + "buildFunctions": "netlify-lambda build functions -c ./webpack.config.js", "test": "react-scripts test --env=jsdom", "eject": "react-scripts eject" }, "devDependencies": { "netlify-lambda": "^0.4.0" + }, + "proxy": { + "/.netlify/functions": { + "target": "http://localhost:9000", + "pathRewrite": { + "^/\\.netlify/functions": "" + } + } } }