start-webpack-dev-server-hot
Hot Module Replacement wrapper for start-webpack-dev-server
It does 3 things:
-
Adds
{hot: true}
indevServerOptions
-
Inserts HMR plugin in your webpack config:
new webpack.HotModuleReplacementPlugin()
-
Insert these 2 files in your entry point(s):
'webpack/hot/dev-server', 'webpack-dev-server/client?',
It basically achieves the same purpose as the webpack-dev-server's CLI switches --hot --inline
Install
npm install --save-dev start-webpack-dev-server-hot# or yarn add --dev start-webpack-dev-server-hot
Usage
;;; const start = ; const dev = ;
Arguments
Since it's basically a wrapper, it accepts the same arguments as start-webpack-dev-server.