Comparing version 5.62.1 to 5.62.2
@@ -186,3 +186,4 @@ /* | ||
syncWebAssembly: options.experiments.syncWebAssembly, | ||
asyncWebAssembly: options.experiments.asyncWebAssembly | ||
asyncWebAssembly: options.experiments.asyncWebAssembly, | ||
futureDefaults | ||
}); | ||
@@ -432,5 +433,10 @@ | ||
* @param {JavascriptParserOptions} parserOptions parser options | ||
* @param {Object} options options | ||
* @param {boolean} options.futureDefaults is future defaults enabled | ||
* @returns {void} | ||
*/ | ||
const applyJavascriptParserOptionsDefaults = parserOptions => { | ||
const applyJavascriptParserOptionsDefaults = ( | ||
parserOptions, | ||
{ futureDefaults } | ||
) => { | ||
D(parserOptions, "unknownContextRequest", "."); | ||
@@ -448,2 +454,3 @@ D(parserOptions, "unknownContextRegExp", false); | ||
D(parserOptions, "strictThisContextOnImports", false); | ||
if (futureDefaults) D(parserOptions, "exportsPresence", "error"); | ||
}; | ||
@@ -457,2 +464,3 @@ | ||
* @param {boolean} options.asyncWebAssembly is asyncWebAssembly enabled | ||
* @param {boolean} options.futureDefaults is future defaults enabled | ||
* @returns {void} | ||
@@ -462,3 +470,3 @@ */ | ||
module, | ||
{ cache, syncWebAssembly, asyncWebAssembly } | ||
{ cache, syncWebAssembly, asyncWebAssembly, futureDefaults } | ||
) => { | ||
@@ -481,3 +489,5 @@ if (cache) { | ||
F(module.parser, "javascript", () => ({})); | ||
applyJavascriptParserOptionsDefaults(module.parser.javascript); | ||
applyJavascriptParserOptionsDefaults(module.parser.javascript, { | ||
futureDefaults | ||
}); | ||
@@ -484,0 +494,0 @@ A(module, "defaultRules", () => { |
@@ -232,2 +232,3 @@ /* | ||
wrappedContextCritical: module.wrappedContextCritical, | ||
// TODO webpack 6 remove | ||
strictExportPresence: module.strictExportPresence, | ||
@@ -234,0 +235,0 @@ strictThisContextOnImports: module.strictThisContextOnImports, |
@@ -26,6 +26,6 @@ /* | ||
this.exportPresenceMode = | ||
options.reexportExportPresence !== undefined | ||
? ExportPresenceModes.fromUserOption(options.reexportExportPresence) | ||
: options.exportPresence !== undefined | ||
? ExportPresenceModes.fromUserOption(options.exportPresence) | ||
options.reexportExportsPresence !== undefined | ||
? ExportPresenceModes.fromUserOption(options.reexportExportsPresence) | ||
: options.exportsPresence !== undefined | ||
? ExportPresenceModes.fromUserOption(options.exportsPresence) | ||
: options.strictExportPresence | ||
@@ -32,0 +32,0 @@ ? ExportPresenceModes.ERROR |
@@ -758,4 +758,4 @@ /* | ||
getWarnings(moduleGraph) { | ||
const exportPresence = this._getEffectiveExportPresenceLevel(moduleGraph); | ||
if (exportPresence === ExportPresenceModes.WARN) { | ||
const exportsPresence = this._getEffectiveExportPresenceLevel(moduleGraph); | ||
if (exportsPresence === ExportPresenceModes.WARN) { | ||
return this._getErrors(moduleGraph); | ||
@@ -772,4 +772,4 @@ } | ||
getErrors(moduleGraph) { | ||
const exportPresence = this._getEffectiveExportPresenceLevel(moduleGraph); | ||
if (exportPresence === ExportPresenceModes.ERROR) { | ||
const exportsPresence = this._getEffectiveExportPresenceLevel(moduleGraph); | ||
if (exportsPresence === ExportPresenceModes.ERROR) { | ||
return this._getErrors(moduleGraph); | ||
@@ -776,0 +776,0 @@ } |
@@ -41,2 +41,4 @@ /* | ||
return ExportPresenceModes.WARN; | ||
case "auto": | ||
return ExportPresenceModes.AUTO; | ||
case false: | ||
@@ -43,0 +45,0 @@ return ExportPresenceModes.NONE; |
@@ -70,6 +70,6 @@ /* | ||
this.exportPresenceMode = | ||
options.importExportPresence !== undefined | ||
? ExportPresenceModes.fromUserOption(options.importExportPresence) | ||
: options.exportPresence !== undefined | ||
? ExportPresenceModes.fromUserOption(options.exportPresence) | ||
options.importExportsPresence !== undefined | ||
? ExportPresenceModes.fromUserOption(options.importExportsPresence) | ||
: options.exportsPresence !== undefined | ||
? ExportPresenceModes.fromUserOption(options.exportsPresence) | ||
: options.strictExportPresence | ||
@@ -76,0 +76,0 @@ ? ExportPresenceModes.ERROR |
@@ -176,4 +176,4 @@ /* | ||
getWarnings(moduleGraph) { | ||
const exportPresence = this._getEffectiveExportPresenceLevel(moduleGraph); | ||
if (exportPresence === ExportPresenceModes.WARN) { | ||
const exportsPresence = this._getEffectiveExportPresenceLevel(moduleGraph); | ||
if (exportsPresence === ExportPresenceModes.WARN) { | ||
return this._getErrors(moduleGraph); | ||
@@ -190,4 +190,4 @@ } | ||
getErrors(moduleGraph) { | ||
const exportPresence = this._getEffectiveExportPresenceLevel(moduleGraph); | ||
if (exportPresence === ExportPresenceModes.ERROR) { | ||
const exportsPresence = this._getEffectiveExportPresenceLevel(moduleGraph); | ||
if (exportsPresence === ExportPresenceModes.ERROR) { | ||
return this._getErrors(moduleGraph); | ||
@@ -194,0 +194,0 @@ } |
@@ -221,3 +221,11 @@ /* | ||
.tap("RuntimePlugin", chunk => { | ||
if (compilation.outputOptions.library.type === "system") { | ||
const { outputOptions } = compilation; | ||
const { library: globalLibrary } = outputOptions; | ||
const entryOptions = chunk.getEntryOptions(); | ||
const libraryType = | ||
entryOptions && entryOptions.library !== undefined | ||
? entryOptions.library.type | ||
: globalLibrary.type; | ||
if (libraryType === "system") { | ||
compilation.addRuntimeModule( | ||
@@ -224,0 +232,0 @@ chunk, |
@@ -1163,3 +1163,3 @@ /* | ||
{ regExp: /\(possible exports: (.+)\)/g, format: green }, | ||
{ regExp: /\s*(.+ doesn't exist)/g, format: red }, | ||
{ regExp: /\s*([^\s].* doesn't exist)/g, format: red }, | ||
{ regExp: /('\w+' option has not been set)/g, format: red }, | ||
@@ -1166,0 +1166,0 @@ { |
{ | ||
"name": "webpack", | ||
"version": "5.62.1", | ||
"version": "5.62.2", | ||
"author": "Tobias Koppers @sokra", | ||
@@ -5,0 +5,0 @@ "description": "Packs CommonJs/AMD modules for the browser. Allows to split your codebase into multiple bundles, which can be loaded on demand. Support loaders to preprocess files, i.e. json, jsx, es7, css, less, ... and your custom stuff.", |
Sorry, the diff of this file is too big to display
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
4173443
120881