Skip to content

armgit / core

Public Imported from GitHub
0

100% open-source IoT Platform - Integrate your devices, add intelligence, build custom apps

Set webpack mode to development for serving files

Rich Turnere5090b7ff148
diff --git a/ui/app/smart-building/package.json b/ui/app/smart-building/package.json
index 388823e63..4d090bf56 100644
--- a/ui/app/smart-building/package.json
+++ b/ui/app/smart-building/package.json
@@ -9,8 +9,8 @@
"clean": "npx shx rm -rf dist",
"modelBuild": "node ../../model-build.js",
"modelWatch": "node ../../model-watch.js",
- "build": "npx tsc -b && npx cross-env NODE_ENV=production webpack",
- "serve": "npx webpack-dev-server",
+ "build": "npx tsc -b && npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack --mode production",
+ "serve": "npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack-dev-server --mode development",
"watch": "npx tsc -b -w",
"test": "echo \"Error: no test specified\" && exit 1"
},
diff --git a/ui/demo/demo-core/package.json b/ui/demo/demo-core/package.json
index a8a8a6cc3..9eb2aee01 100644
--- a/ui/demo/demo-core/package.json
+++ b/ui/demo/demo-core/package.json
@@ -7,8 +7,8 @@
"clean": "npx shx rm -rf dist",
"modelBuild": "node ../../model-build.js",
"modelWatch": "node ../../model-watch.js",
- "build": "npx tsc -b && npx cross-env NODE_ENV=production webpack",
- "serve": "npx webpack-dev-server",
+ "build": "npx tsc -b && npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack --mode production",
+ "serve": "npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack-dev-server --mode development",
"watch": "npx tsc -b -w",
"test": "echo \"Error: no test specified\" && exit 1"
},
diff --git a/ui/demo/demo-or-header/package.json b/ui/demo/demo-or-header/package.json
index 8a8816f8a..287f45ca5 100644
--- a/ui/demo/demo-or-header/package.json
+++ b/ui/demo/demo-or-header/package.json
@@ -6,8 +6,8 @@
"clean": "npx shx rm -rf dist",
"modelBuild": "node ../../model-build.js",
"modelWatch": "node ../../model-watch.js",
- "build": "npx tsc -b && npx cross-env NODE_ENV=production webpack",
- "serve": "npx webpack-dev-server",
+ "build": "npx tsc -b && npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack --mode production",
+ "serve": "npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack-dev-server --mode development",
"watch": "npx tsc -b -w",
"test": "echo \"Error: no test specified\" && exit 1"
},
diff --git a/ui/demo/demo-or-map/package.json b/ui/demo/demo-or-map/package.json
index 350ffb695..ff5ad55de 100644
--- a/ui/demo/demo-or-map/package.json
+++ b/ui/demo/demo-or-map/package.json
@@ -6,8 +6,8 @@
"clean": "npx shx rm -rf dist",
"modelBuild": "node ../../model-build.js",
"modelWatch": "node ../../model-watch.js",
- "build": "npx tsc -b && npx cross-env NODE_ENV=production webpack",
- "serve": "npx webpack-dev-server",
+ "build": "npx tsc -b && npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack --mode production",
+ "serve": "npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack-dev-server --mode development",
"watch": "npx tsc -b -w",
"test": "echo \"Error: no test specified\" && exit 1"
},
diff --git a/ui/demo/demo-or-thermostat/package.json b/ui/demo/demo-or-thermostat/package.json
index d8b59d6b1..30b9197e3 100644
--- a/ui/demo/demo-or-thermostat/package.json
+++ b/ui/demo/demo-or-thermostat/package.json
@@ -6,8 +6,8 @@
"clean": "npx shx rm -rf dist",
"modelBuild": "node ../../model-build.js",
"modelWatch": "node ../../model-watch.js",
- "build": "npx tsc -b && npx cross-env NODE_ENV=production webpack",
- "serve": "npx webpack-dev-server",
+ "build": "npx tsc -b && npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack --mode production",
+ "serve": "npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack-dev-server --mode development",
"watch": "npx tsc -b -w",
"test": "echo \"Error: no test specified\" && exit 1"
},
diff --git a/ui/demo/demo-rest/package.json b/ui/demo/demo-rest/package.json
index 27452cab1..c65f6342c 100644
--- a/ui/demo/demo-rest/package.json
+++ b/ui/demo/demo-rest/package.json
@@ -7,8 +7,8 @@
"clean": "npx shx rm -rf dist",
"modelBuild": "node ../../model-build.js",
"modelWatch": "node ../../model-watch.js",
- "build": "npx tsc -b && npx cross-env NODE_ENV=production webpack",
- "serve": "npx webpack-dev-server",
+ "build": "npx tsc -b && npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack --mode production",
+ "serve": "npx cross-env NODE_OPTIONS=--max_old_space_size=4096 webpack-dev-server --mode development",
"watch": "npx tsc -b -w",
"test": "echo \"Error: no test specified\" && exit 1"
},