Skip to content

Commit f0dc459

Browse files
Downloaddevelopit
authored andcommitted
Added cross-env for setting env cross-platform (#42)
Fixes npm run dev fails on Windows Download#3 SEE Build does not work on Windows #41
1 parent 09cd64a commit f0dc459

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33
"version": "4.0.0",
44
"description": "Ready-to-go Preact starter project powered by webpack.",
55
"scripts": {
6-
"dev": "NODE_ENV=development webpack-dev-server --inline --hot --progress",
6+
"dev": "cross-env NODE_ENV=development webpack-dev-server --inline --hot --progress",
77
"start": "superstatic build -p ${PORT:-8080} --host 0.0.0.0 --gzip -c '{\"rewrites\": [{\"source\":\"**\",\"destination\":\"index.html\"}],\"headers\":[{\"source\":\"**\",\"headers\":[{\"key\":\"Cache-Control\",\"value\":\"max-age=86400\"}]}]}'",
88
"prestart": "npm run build",
9-
"build": "NODE_ENV=production webpack -p --progress",
9+
"build": "cross-env NODE_ENV=production webpack -p --progress",
1010
"prebuild": "mkdir -p build && ncp src/assets build/assets",
1111
"test": "npm run -s lint && npm run -s test:karma",
1212
"test:karma": "karma start test/karma.conf.js --single-run",
@@ -34,6 +34,7 @@
3434
"babel-runtime": "^6.6.1",
3535
"chai": "^3.5.0",
3636
"core-js": "^2.2.1",
37+
"cross-env": "^2.0.0",
3738
"css-loader": "^0.23.1",
3839
"eslint": "^3.0.1",
3940
"extract-text-webpack-plugin": "^1.0.1",

0 commit comments

Comments
 (0)