diff --git a/package.json b/package.json index 4fd7e89..c2d949a 100644 --- a/package.json +++ b/package.json @@ -6,8 +6,7 @@ "scripts": { "clean": "rimraf bundle.js bundle.js.map", "build": "webpack --config=webpack.config.js -p", - "postinstall": "$npm_execpath run clean && $npm_execpath run build", - "start": "node server.js", + "start": "$npm_execpath run build && node server.js", "dev": "webpack-dev-server --inline --hot", "lint": "$npm_execpath run lint:js && $npm_execpath run lint:markdown", "lint:js": "eslint --cache --ext .js,.jsx src *.js", diff --git a/server.js b/server.js index ffb2d94..4c4283f 100644 --- a/server.js +++ b/server.js @@ -10,6 +10,7 @@ app.use(bodyParser.json({ type: 'application/*+json' })); app.use(express.static(__dirname)); // Check if we're running on a local dev machine +// TODO: Remove use of .env. Change instructions to direct users to direnv if (fs.existsSync('./.env')) { // Load environment variables from .env require('dotenv').config();