Skip to content

Commit d5b6606

Browse files
xqbumuPanJiaChen
authored andcommitted
更新node-sass和增加跨平台执行npm run build的环境变量问题
解决windows10 64bit 下 sass 编译报错,和跨平台下的执行 npm run build:xxx 错误
1 parent c96151d commit d5b6606

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

package.json

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
"private": true,
88
"scripts": {
99
"dev": "node build/dev-server.js",
10-
"build:prod": "NODE_ENV=production node build/build.js",
11-
"build:sit": "NODE_ENV=sit node build/build.js",
12-
"build:sit-preview": "NODE_ENV=sit npm_config_preview=true npm_config_report=true node build/build.js",
10+
"build:prod": "cross-env NODE_ENV=production node build/build.js",
11+
"build:sit": "cross-env NODE_ENV=sit node build/build.js",
12+
"build:sit-preview": "cross-env NODE_ENV=sit npm_config_preview=true npm_config_report=true node build/build.js",
1313
"lint": "eslint --ext .js,.vue src"
1414
},
1515
"dependencies": {
@@ -49,6 +49,7 @@
4949
"chalk": "1.1.3",
5050
"connect-history-api-fallback": "1.3.0",
5151
"copy-webpack-plugin": "4.0.1",
52+
"cross-env": "^4.0.0",
5253
"css-loader": "0.26.1",
5354
"eslint": "3.14.1",
5455
"eslint-config-airbnb-base": "11.0.1",
@@ -65,7 +66,7 @@
6566
"function-bind": "1.1.0",
6667
"html-webpack-plugin": "2.28.0",
6768
"http-proxy-middleware": "0.17.3",
68-
"node-sass": "3.7.0",
69+
"node-sass": "4.5.2",
6970
"opn": "4.0.2",
7071
"optimize-css-assets-webpack-plugin": "1.3.0",
7172
"ora": "1.1.0",

0 commit comments

Comments
 (0)