When writing essays: webpack4.6.0
Why is the title used? Because Swaiiow is not sure whether to use the correct words, it is probably the saying:
Webpack4.0 introduces production mode and development mode, and does not compress after using webpack in development, so only--mode mode development can be added to Webpack packaging commands. If you do not have mode development will automatically use the production mode, all the packaged code will be compressed, there is no way to debug
Practice:
The Bundle.js file introduced by index.html must be the path to Webpack-dev-server because Bundle.js is dynamically created
The startup mode of Webpack-dev-server is tested:
Configuration under Package.json:
"Scripts": {"test": "Echo \" Error:no test specified\ "&& exit 1","dev": "Webpack-dev-server-- Mode development "," server ":" Webpack-dev-server "," Serverhot ":" Webpack-dev-server--hot--inline " }
Start with development: Update fast, modify the entry file, immediately refresh no parameters: will be automatically compiled and refreshed, very slow--hot--inline will be automatically compiled, but will not refresh, should be for the module load????
About Webpack under hot update? & Auto Refresh? (Non-VUE-CLI)