less-loader 12.3.2 → 12.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -13,7 +13,7 @@ async function lessLoader(source) {
13
13
  const callback = this.async();
14
14
  let implementation;
15
15
  try {
16
- implementation = await (0, _utils.getLessImplementation)(this, options.implementation);
16
+ implementation = (0, _utils.getLessImplementation)(this, options.implementation);
17
17
  } catch (error) {
18
18
  callback(error);
19
19
  return;
package/dist/utils.js CHANGED
@@ -181,15 +181,16 @@ function normalizeSourceMap(map) {
181
181
  delete newMap.file;
182
182
  newMap.sourceRoot = "";
183
183
 
184
- // `less` (old versions) returns POSIX paths, that's why we need to transform them back to native paths.
184
+ // `less` returns POSIX paths, that's why we need to transform them back to native paths.
185
+
185
186
  newMap.sources = newMap.sources.map(source => _nodePath.default.normalize(source));
186
187
  return newMap;
187
188
  }
188
- async function getLessImplementation(loaderContext, implementation) {
189
+ function getLessImplementation(loaderContext, implementation) {
189
190
  let resolvedImplementation = implementation;
190
191
  if (!implementation || typeof implementation === "string") {
191
192
  const lessImplPkg = implementation || "less";
192
- resolvedImplementation = (await import(lessImplPkg)).default;
193
+ resolvedImplementation = require(lessImplPkg);
193
194
  }
194
195
  return resolvedImplementation;
195
196
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "less-loader",
3
- "version": "12.3.2",
3
+ "version": "12.3.3",
4
4
  "description": "A Less loader for webpack. Compiles Less to CSS.",
5
5
  "keywords": [
6
6
  "webpack",
@@ -38,7 +38,7 @@
38
38
  "fix:js": "npm run lint:js -- --fix",
39
39
  "fix:prettier": "npm run lint:prettier -- --write",
40
40
  "fix": "npm-run-all -l fix:js fix:prettier",
41
- "test:only": "node --experimental-vm-modules node_modules/jest-cli/bin/jest.js",
41
+ "test:only": "cross-env NODE_ENV=test jest",
42
42
  "test:watch": "npm run test:only -- --watch",
43
43
  "test:coverage": "npm run test:only -- --collectCoverageFrom=\"src/**/*.js\" --coverage",
44
44
  "pretest": "npm run lint",
@@ -61,7 +61,7 @@
61
61
  "eslint-config-webpack": "^4.5.1",
62
62
  "husky": "^9.1.3",
63
63
  "jest": "^30.0.0",
64
- "less": "^4.6.2",
64
+ "less": "^4.6.3",
65
65
  "less-plugin-glob": "^3.0.0",
66
66
  "lint-staged": "^15.2.7",
67
67
  "memfs": "^4.9.3",