loader-utils
Advanced tools
Changelog
3.0.0 (2021-10-20)
12.13.0
(93a87ce)xxhash64
by default for [hash]
/[contenthash]
and getHashDigest
API[emoji]
was removed without replacements, please use custom function if you need thisgetOptions
in favor loaderContext.getOptions
(loaderContext
is this
inside loader function), note - special query parameters like ?something=true
is not supported anymore, if you need this please do it on loader
side, but we strongly recommend avoid it, as alternative you can use ?something=1
and handle 1
as true
getRemainingRequest
in favor loaderContext.remainingRequest
(loaderContext
is this
inside loader function)getCurrentRequest
in favor loaderContext.currentRequest
(loaderContext
is this
inside loader function)parseString
in favor JSON.parse
parseQuery
in favor new URLSearchParams(loaderContext.resourceQuery.slice(1))
where loaderContext
is this
in loader functionstringifyRequest
in favor JSON.stringify(loaderContext.utils.contextify(loaderContext.context || loaderContext.rootContext, request))
(loaderContext
is this
inside loader function), also it will be cachable and fasterisUrlRequest
ignores only absolute URLs and #hash
requests, data URI
and root relative request are handled as requestable due webpack v5 support theminterpolateName
API works without options (862ea7d)