For webpack learning path
reference: webpack series
webpack configuration template exercise
- Introduce vue and jq, (hope to achieve, multi-page application + jq framework,)
- When introducing monitoring.js, you can ignore unnecessary language packs and manually introduce the corresponding language;
- For some optimization items, you can use dllpulgin to dynamically link the manifest.json file
- Use happypack for multi-threaded packaging, id,
- optimization(chunkCommonPlugin) Multi-page, extract the repeated reference files and put them in one file
- do while execute at least once
-
Import html files, import plugin html-webpack-plugin
-
css, note: loader is right to left, execute from bottom to top
- The first is style-loader css-loader,
mini-css-extract-plugin,
optimize-css-assets-webpack-plugin//compress
uglifyjs-webpack-plugin
postcss-loader (plus prefix) (less)less-loader, node -sass,(sass-loader) ,stylus-loader
- js module
- (babel), babel-loader, @babel/core, @babel/preset-env (conversion es6 syntax), @babel/plugin-proposal-class-properties (class syntax)
- "@Babel/plugin-transform-runtime" (run)
"html-webpack-plugin" (production environment)