Webpack 4.30 is required for acorn 6 transition. Needs webassemblyjs - ITP 942455.
Webpack 4.7 is available in unstable.
- Run tests (currently disabled because jest is not packaged).
Now entry, output options on command line are mandatory and we get a warning if mode option is not specified. Check node-d3-request (commit)
production and development are new modes and each has its on default options. production mode does minify by default.
entry option in command line must have ./ prefix to directory path (--entry src/index.js will not work, but --entry ./src/index.js will work). See node-turbolinks commit.
- Output files are now created under dist directory by default.
node_modules/.cache should be removed in clean target.
node-grunt-webpack should be >= 3.1.
webpack.optimize.UglifyJsPlugin has been removed, please use config.optimization.minimize instead. Check this patch or this commit (where a single config file creates multiple output files and only one of them we need minimized). Replace "plugin" field with "optimization" or remove "plugin" field and just set "mode" to production.
configuration.module has an unknown property 'loaders'. Change loaders to rules under modules. Example commit
Steps to build with webpack 4
clone repo from salsa (gbp clone --pristine-tar)
Update debian/control and change webpack dependency to >= 4~ to force building with webpack 4 (without this, package in unstable will be used).
Build on experimental. See sbuild#Enabling_experimental
Command used to find the list: reverse-depends -b webpack
Packages for upstream modification
node-node-forge -- Kannan - done
node-axios -- Kannan - doing
Already compatible with webpack 4
- node-mocha (false positive, switched to rollup)
- node-js-beautify (tested rebuild)
Ready in unstable
- node-rollup-plugin-alias (switched to rollup)
- node-chai (minor todo: minify only .min.js)
node-axios , node-handlebars 933868
Ready with patch in BTS/git repo
node-node-forge, node-jsonld, node-rdf-canonize 933592
Supported in new upstream release
Packages that needs to move to unstable with webpack 4
pkg-js-tools (>= 0.8.4~) - ok
node-ajv (>= 6.1~) - ok
node-ajv-keywords (>= 3.1~) - ok
node-enhanced-resolve (>= 4.0~) - ok
node-micromatch (>= 3.1.8~) - skipped for later
node-schema-utils (>= 0.4.2~) - ok
node-tapable (>= 1.0~) - ok
node-uglifyjs-webpack-plugin (>= 1.3.0-4~) - ok
node-watchpack (>= 1.4~) - ok
node-chokidar (>= 2~) - ok