@samitouri / QOS-React / commits / 947e3c2c04

Add production mode to dev shell

Dan Abramov committed Apr 15, 2019 at 15:39 UTC 947e3c2c049c006da9ed814ded04583edfe4ff3d
2 files changed +2 -1
package.json
+1
@@ -48,6 +48,7 @@
48 "prettier": "prettier --write '**/*.{js,json,css}'",
49 "prettier:ci": "prettier --check '**/*.{js,json,css}'",
50 "start": "cd ./shells/dev && opener ./index.html && webpack --config webpack.config.js --watch",
51 + "start:prod": "cross-env NODE_ENV=production npm start",
52 "test": "jest",
53 "test-debug": "node --inspect-brk node_modules/.bin/jest --runInBand",
54 "test:chrome": "node ./shells/browser/chrome/test",
shells/dev/webpack.config.js
+1 -1
@@ -9,7 +9,7 @@ const GITHUB_URL = getGitHubURL();
9 const DEVTOOLS_VERSION = getVersionString();
10
11 module.exports = {
12 - mode: 'development',
12 + mode: __DEV__ ? 'development' : 'production',
13 devtool: false,
14 entry: {
15 app: './app/index.js',