image-minimizer-webpack-plugin
Advanced tools
Changelog
3.0.0 (2021-12-05)
There are a lot of breaking changes, the plugin has been completely rewritten, see the documentation for information and examples.
12.13.0
, imagemin
uses dynamic import()
to load plugins, so your Node.js version should support itimagemin
, so you need to run npm i -D imagemin
to install imagemin
minify
and minizerOptions
in one option - minimizer
, you can use minimizer.implementation
and minimizer.options
to specify minimizer and optionsgenerator
option to configure image generation and use new URL("./image.png?as=webp")
/div { backgaround: url("./image.png?as=webp"); }
/etc in code to enable it (import
and require
are supported too)filter
and filename
option was moved in the minimizer
/generator
optionimageminNormalizeConfig
is now async functionseverityError
option is "error"
, removed values: true
, false
and auto
.
(dot) before [ext]
in the filename
optionsquoosh
supportminimizer
option for image optimizationgenerator
option for image generationminimizer
option featurefilename
option will be Function
imagemin
plugindata:
/http:
/https:
/file: