refactor: towards server HMR
This commit is contained in:
parent
d9d3e5a84b
commit
3e9921c2a4
|
@ -11,7 +11,7 @@
|
|||
"electron": "NODE_ENV=production NODE_PATH=./node_modules electron build/electron.js",
|
||||
"lint": "latus-build lint",
|
||||
"repl": "rlwrap -C qmp socat STDIO UNIX:$(ls /tmp/latus-*.sock | tail -n 1)",
|
||||
"server": "LATUS_EXCLUDE_BUILD=http latus-build -d --hot --start-server --inspect",
|
||||
"server": "LATUS_EXCLUDE_BUILD=http latus-build -d --hot --start-server --inspect --watch",
|
||||
"start": "NODE_ENV=production NODE_PATH=./node_modules node build/index.js",
|
||||
"test": "latus-build test"
|
||||
},
|
||||
|
@ -53,6 +53,7 @@
|
|||
"history": "^4.7.2",
|
||||
"is-electron": "^2.2.0",
|
||||
"pixi.js-legacy": "^5.3.7",
|
||||
"react-hot-loader": "4.13.0",
|
||||
"react-router": "^5.2.0",
|
||||
"react-router-dom": "^5.2.0",
|
||||
"screenfull": "^5.1.0"
|
||||
|
|
|
@ -6,9 +6,8 @@ const neutrino = require('neutrino');
|
|||
const server = require('./.neutrinorc');
|
||||
|
||||
const {
|
||||
LATUS_EXCLUDE_BUILD = ''
|
||||
LATUS_EXCLUDE_BUILD = '',
|
||||
} = process.env;
|
||||
|
||||
const excludeBuilds = LATUS_EXCLUDE_BUILD.split(',').map((name) => name.trim());
|
||||
|
||||
module.exports = process.env.LATUS_LINTING
|
||||
|
@ -29,9 +28,12 @@ module.exports = process.env.LATUS_LINTING
|
|||
)
|
||||
)
|
||||
.map((config) => neutrino(config).webpack());
|
||||
if (webpackConfigs.length > 0) {
|
||||
if (webpackConfigs.length > 1) {
|
||||
resolve(webpackConfigs);
|
||||
}
|
||||
if (1 === webpackConfigs.length) {
|
||||
resolve(webpackConfigs[0]);
|
||||
}
|
||||
}
|
||||
catch (error) {
|
||||
reject(error);
|
||||
|
|
|
@ -8414,7 +8414,7 @@ react-hex-editor@^0.3.0:
|
|||
react-virtualized-auto-sizer "^1.0.2"
|
||||
react-window "^1.8.5"
|
||||
|
||||
react-hot-loader@^4.13.0:
|
||||
react-hot-loader@4.13.0, react-hot-loader@^4.13.0:
|
||||
version "4.13.0"
|
||||
resolved "http://npm.cha0sdev/react-hot-loader/-/react-hot-loader-4.13.0.tgz#c27e9408581c2a678f5316e69c061b226dc6a202"
|
||||
integrity sha512-JrLlvUPqh6wIkrK2hZDfOyq/Uh/WeVEr8nc7hkn2/3Ul0sx1Kr5y4kOGNacNRoj7RhwLNcQ3Udf1KJXrqc0ZtA==
|
||||
|
|
Loading…
Reference in New Issue
Block a user