We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 60c3755 commit fee0582Copy full SHA for fee0582
src/utils.js
@@ -22,7 +22,17 @@ function isRelativePath(str) {
22
return matchRelativePath.test(str);
23
}
24
25
+// TODO simplify for the next major release
26
function stringifyRequest(loaderContext, request) {
27
+ if (
28
+ typeof loaderContext.utils !== "undefined" &&
29
+ typeof loaderContext.utils.contextify === "function"
30
+ ) {
31
+ return JSON.stringify(
32
+ loaderContext.utils.contextify(loaderContext.context, request)
33
+ );
34
+ }
35
+
36
const splitted = request.split("!");
37
const { context } = loaderContext;
38
0 commit comments