node-hot-loader
Advanced tools
Comparing version 1.1.3 to 1.2.0
@@ -32,7 +32,9 @@ 'use strict'; | ||
var config = Array.isArray(webpackConfig) ? webpackConfig.find(function (c) { | ||
return c.target === 'node'; | ||
}) : webpackConfig; | ||
if (config.target !== 'node') { | ||
throw new Error('Webpack configuration file must provide config with target "node".'); | ||
if (!config) { | ||
throw new Error('Not found webpack configuration. For multiple configurations in single file you must provide config with target "node".'); | ||
} | ||
@@ -39,0 +41,0 @@ |
{ | ||
"name": "node-hot-loader", | ||
"version": "1.1.3", | ||
"version": "1.2.0", | ||
"description": "Hot module replacement for Node.js applications", | ||
@@ -5,0 +5,0 @@ "main": "./lib/node-hot.js", |
@@ -51,6 +51,2 @@ # Node Hot Loader [![npm package](https://img.shields.io/npm/v/node-hot-loader.svg?style=flat-square)](https://www.npmjs.org/package/node-hot-loader) | ||
export default { | ||
// It's required! | ||
// Also if you use multiconfigurations node-hot choose configuration with target 'node'. | ||
target: 'node', | ||
// node-hot run the all entries in one child process. | ||
@@ -120,3 +116,3 @@ // And the all entries will be with HMR support. | ||
}) | ||
.catch(console.error); | ||
.catch(err => console.error(err)); | ||
}); | ||
@@ -123,0 +119,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
622
30598
141