Webpack plugin that automatically (re)starts your server between builds.
- Remove your dependency on
nodemon
,forever
,pm2
, or similar. - This works better from a "cold start" when your server hasn't been built yet.
- Fewer issues with websockets & hot-module reloading.
$ npm install --save-dev reload-server-webpack-plugin
Update your webpack.config.js
:
module.exports = {
...
plugins: [
new ReloadServerPlugin({
// Defaults to process.cwd() + "/server.js"
script: "path/to/server.js",
}),
],
...
};
MIT License 2015 © Eric Clemmons