magic-comments-loader
Advanced tools
Comparing version 1.3.1 to 1.3.2
@@ -16,3 +16,3 @@ "use strict"; | ||
const dynamicImportsWithoutComments = /(?<![\w.]|#!|\*[\s\w]*?|\/\/\s*)import\s*\((?!\s*\/\*)(?<path>\s*?['"`][^)]+['"`]\s*)\)(?![\s]*?\*\/)/g; | ||
var _util = require("./util.js"); | ||
@@ -31,5 +31,5 @@ const loader = function (source, map, meta) { | ||
}, logger); | ||
this.callback(null, source.replace(dynamicImportsWithoutComments, magicComments), map, meta); | ||
this.callback(null, source.replace(_util.dynamicImportsWithoutComments, magicComments), map, meta); | ||
}; | ||
exports.loader = loader; |
{ | ||
"name": "magic-comments-loader", | ||
"version": "1.3.1", | ||
"version": "1.3.2", | ||
"description": "Add webpack magic comments to your dynamic imports during build time", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -6,3 +6,3 @@ "use strict"; | ||
}); | ||
exports.importPrefix = exports.pathIsMatch = exports.getOverrideSchema = exports.getOverrideConfig = void 0; | ||
exports.dynamicImportsWithoutComments = exports.importPrefix = exports.pathIsMatch = exports.getOverrideSchema = exports.getOverrideConfig = void 0; | ||
@@ -72,2 +72,4 @@ var _micromatch = _interopRequireDefault(require("micromatch")); | ||
const importPrefix = /^(?:(\.{1,2}\/)+)|^\/|^.+:\/\/\/?[.-\w]+\//; | ||
exports.importPrefix = importPrefix; | ||
exports.importPrefix = importPrefix; | ||
const dynamicImportsWithoutComments = /(?<![\w.]|#!|\*[\s\w]*?|\/\/\s*|['"`][^)$]*)import\s*\((?!\s*\/\*)(?<path>\s*?['"`][^)]+['"`]\s*)\)(?!\s*?\*\/)/g; | ||
exports.dynamicImportsWithoutComments = dynamicImportsWithoutComments; |
{ | ||
"name": "magic-comments-loader", | ||
"version": "1.3.1", | ||
"version": "1.3.2", | ||
"description": "Add webpack magic comments to your dynamic imports during build time", | ||
@@ -5,0 +5,0 @@ "main": "dist", |
@@ -37,3 +37,3 @@ # [`magic-comments-loader`](https://www.npmjs.com/package/magic-comments-loader) | ||
This module uses a [RegExp](https://github.com/morganney/magic-comments-loader/blob/master/src/loader.js#L8) not a parser. If you would like to add better support for ignoring `import()` behind multiline comments please open a pull request. See some more [examples on regexr](https://regexr.com/65fg0). | ||
This module uses a RegExp not a parser. If you would like to add better support for ignoring `import()` behind multiline comments please open a pull request. See some more [examples on regexr](https://regexr.com/65fg0). | ||
@@ -40,0 +40,0 @@ ### Configuration |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
29139
580