Browse Source

Use cross-env for setting NODE_ENV in watch-html script for better compatibility

codecalm 1 month ago
parent
commit
cac2606016
1 changed files with 1 additions and 1 deletions
  1. 1 1
      preview/package.json

+ 1 - 1
preview/package.json

@@ -5,7 +5,7 @@
     "build": "pnpm run clean && pnpm run css && pnpm run js && pnpm run html",
     "dev": "pnpm run clean && pnpm run watch",
     "watch": "pnpm run watch-html & pnpm run watch-css & pnpm run watch-js",
-    "watch-html": "NODE_ENV=development eleventy --serve --port=3000 --incremental",
+    "watch-html": "cross-env NODE_ENV=development eleventy --serve --port=3000 --incremental",
     "watch-js": "nodemon --watch js/ --ext js --exec 'pnpm run js'",
     "watch-css": "nodemon --watch scss/ --ext scss --exec 'pnpm run css'",
     "css": "pnpm run css-compile && pnpm run css-prefix && pnpm run css-minify",