webpack 5.100.2 → 5.101.0
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/README.md +12 -10
- package/bin/webpack.js +7 -7
- package/lib/APIPlugin.js +12 -14
- package/lib/AutomaticPrefetchPlugin.js +2 -2
- package/lib/BannerPlugin.js +4 -4
- package/lib/Cache.js +1 -1
- package/lib/CacheFacade.js +7 -7
- package/lib/CaseSensitiveModulesWarning.js +2 -2
- package/lib/Chunk.js +3 -3
- package/lib/ChunkGraph.js +21 -18
- package/lib/ChunkGroup.js +4 -4
- package/lib/CleanPlugin.js +19 -53
- package/lib/CodeGenerationResults.js +3 -3
- package/lib/CompatibilityPlugin.js +6 -6
- package/lib/Compilation.js +126 -113
- package/lib/Compiler.js +37 -37
- package/lib/ConcatenationScope.js +39 -1
- package/lib/ConstPlugin.js +11 -11
- package/lib/ContextExclusionPlugin.js +3 -3
- package/lib/ContextModule.js +12 -11
- package/lib/ContextModuleFactory.js +11 -11
- package/lib/ContextReplacementPlugin.js +5 -5
- package/lib/DefinePlugin.js +24 -22
- package/lib/DelegatedModuleFactoryPlugin.js +1 -1
- package/lib/DllEntryPlugin.js +1 -1
- package/lib/DllReferencePlugin.js +1 -1
- package/lib/DynamicEntryPlugin.js +3 -3
- package/lib/EntryPlugin.js +1 -1
- package/lib/EnvironmentPlugin.js +1 -1
- package/lib/ErrorHelpers.js +2 -2
- package/lib/EvalDevToolModulePlugin.js +2 -2
- package/lib/EvalSourceMapDevToolPlugin.js +5 -5
- package/lib/ExportsInfo.js +9 -9
- package/lib/ExportsInfoApiPlugin.js +2 -2
- package/lib/ExternalModule.js +163 -48
- package/lib/ExternalModuleFactoryPlugin.js +2 -2
- package/lib/ExternalsPlugin.js +45 -0
- package/lib/FileSystemInfo.js +64 -61
- package/lib/FlagAllModulesAsUsedPlugin.js +2 -2
- package/lib/FlagDependencyExportsPlugin.js +7 -7
- package/lib/FlagDependencyUsagePlugin.js +4 -4
- package/lib/FlagEntryExportAsUsedPlugin.js +1 -1
- package/lib/HotModuleReplacementPlugin.js +27 -27
- package/lib/IgnorePlugin.js +3 -3
- package/lib/IgnoreWarningsPlugin.js +4 -4
- package/lib/InitFragment.js +6 -0
- package/lib/InvalidDependenciesModuleWarning.js +1 -1
- package/lib/JavascriptMetaInfoPlugin.js +1 -1
- package/lib/LibManifestPlugin.js +2 -2
- package/lib/LoaderOptionsPlugin.js +1 -1
- package/lib/LoaderTargetPlugin.js +2 -2
- package/lib/MainTemplate.js +1 -1
- package/lib/Module.js +1 -1
- package/lib/ModuleFilenameHelpers.js +3 -3
- package/lib/ModuleGraph.js +9 -5
- package/lib/ModuleInfoHeaderPlugin.js +3 -3
- package/lib/ModuleParseError.js +5 -3
- package/lib/MultiCompiler.js +29 -24
- package/lib/MultiStats.js +18 -13
- package/lib/MultiWatching.js +1 -1
- package/lib/NoEmitOnErrorsPlugin.js +2 -2
- package/lib/NodeStuffPlugin.js +27 -15
- package/lib/NormalModule.js +23 -23
- package/lib/NormalModuleFactory.js +23 -21
- package/lib/NormalModuleReplacementPlugin.js +3 -3
- package/lib/PrefetchPlugin.js +1 -1
- package/lib/ProgressPlugin.js +11 -11
- package/lib/ProvidePlugin.js +2 -2
- package/lib/RecordIdsPlugin.js +3 -3
- package/lib/ResolverFactory.js +3 -3
- package/lib/RuntimeGlobals.js +20 -0
- package/lib/RuntimePlugin.js +16 -16
- package/lib/RuntimeTemplate.js +35 -26
- package/lib/SizeFormatHelpers.js +1 -1
- package/lib/SourceMapDevToolModuleOptionsPlugin.js +4 -4
- package/lib/SourceMapDevToolPlugin.js +9 -9
- package/lib/Stats.js +2 -2
- package/lib/Template.js +1 -1
- package/lib/TemplatedPathPlugin.js +2 -2
- package/lib/UseStrictPlugin.js +1 -1
- package/lib/WarnCaseSensitiveModulesPlugin.js +1 -1
- package/lib/WarnDeprecatedOptionPlugin.js +1 -1
- package/lib/WarnNoModeSetPlugin.js +1 -1
- package/lib/WatchIgnorePlugin.js +2 -2
- package/lib/Watching.js +12 -12
- package/lib/WebpackIsIncludedPlugin.js +2 -2
- package/lib/WebpackOptionsApply.js +3 -3
- package/lib/asset/AssetGenerator.js +1 -1
- package/lib/asset/AssetModulesPlugin.js +6 -6
- package/lib/async-modules/AsyncModuleHelpers.js +1 -1
- package/lib/async-modules/AwaitDependenciesInitFragment.js +36 -24
- package/lib/async-modules/InferAsyncModulesPlugin.js +3 -3
- package/lib/buildChunkGraph.js +5 -5
- package/lib/cache/AddBuildDependenciesPlugin.js +1 -1
- package/lib/cache/IdleFileCachePlugin.js +5 -5
- package/lib/cache/PackFileCacheStrategy.js +20 -20
- package/lib/cache/ResolverCachePlugin.js +4 -4
- package/lib/cli.js +196 -14
- package/lib/config/browserslistTargetHandler.js +6 -6
- package/lib/config/defaults.js +23 -14
- package/lib/config/normalization.js +41 -38
- package/lib/config/target.js +4 -4
- package/lib/container/ContainerEntryModule.js +3 -3
- package/lib/container/ContainerPlugin.js +3 -3
- package/lib/container/ContainerReferencePlugin.js +3 -3
- package/lib/container/FallbackModule.js +1 -1
- package/lib/container/HoistContainerReferencesPlugin.js +7 -7
- package/lib/container/options.js +4 -4
- package/lib/css/CssGenerator.js +5 -3
- package/lib/css/CssLoadingRuntimeModule.js +1 -1
- package/lib/css/CssModulesPlugin.js +25 -22
- package/lib/css/CssParser.js +5 -5
- package/lib/css/walkCssTokens.js +9 -9
- package/lib/debug/ProfilingPlugin.js +5 -5
- package/lib/dependencies/AMDDefineDependencyParserPlugin.js +4 -4
- package/lib/dependencies/AMDPlugin.js +3 -3
- package/lib/dependencies/AMDRequireArrayDependency.js +1 -1
- package/lib/dependencies/AMDRequireDependenciesBlockParserPlugin.js +3 -3
- package/lib/dependencies/CommonJsExportRequireDependency.js +2 -2
- package/lib/dependencies/CommonJsExportsParserPlugin.js +12 -10
- package/lib/dependencies/CommonJsImportsParserPlugin.js +21 -19
- package/lib/dependencies/CommonJsPlugin.js +2 -2
- package/lib/dependencies/ContextDependency.js +1 -1
- package/lib/dependencies/ContextDependencyHelpers.js +3 -3
- package/lib/dependencies/CssIcssExportDependency.js +2 -2
- package/lib/dependencies/CssLocalIdentifierDependency.js +2 -2
- package/lib/dependencies/CssUrlDependency.js +4 -4
- package/lib/dependencies/DynamicExports.js +5 -5
- package/lib/dependencies/HarmonyAcceptDependency.js +39 -5
- package/lib/dependencies/HarmonyDetectionParserPlugin.js +2 -2
- package/lib/dependencies/HarmonyExportDependencyParserPlugin.js +17 -13
- package/lib/dependencies/HarmonyExportImportedSpecifierDependency.js +7 -8
- package/lib/dependencies/HarmonyExportInitFragment.js +1 -1
- package/lib/dependencies/HarmonyExports.js +1 -1
- package/lib/dependencies/HarmonyImportDependency.js +28 -9
- package/lib/dependencies/HarmonyImportDependencyParserPlugin.js +56 -48
- package/lib/dependencies/HarmonyImportSideEffectDependency.js +4 -5
- package/lib/dependencies/HarmonyImportSpecifierDependency.js +3 -4
- package/lib/dependencies/HarmonyModulesPlugin.js +2 -8
- package/lib/dependencies/HarmonyTopLevelThisParserPlugin.js +1 -1
- package/lib/dependencies/ImportMetaContextDependencyParserPlugin.js +4 -4
- package/lib/dependencies/ImportMetaPlugin.js +7 -7
- package/lib/dependencies/ImportParserPlugin.js +4 -4
- package/lib/dependencies/JsonExportsDependency.js +1 -1
- package/lib/dependencies/LoaderPlugin.js +4 -4
- package/lib/dependencies/ProvidedDependency.js +2 -2
- package/lib/dependencies/PureExpressionDependency.js +1 -1
- package/lib/dependencies/RequireContextDependencyParserPlugin.js +1 -1
- package/lib/dependencies/RequireEnsureDependenciesBlockParserPlugin.js +1 -1
- package/lib/dependencies/RequireIncludeDependencyParserPlugin.js +3 -3
- package/lib/dependencies/SystemPlugin.js +3 -3
- package/lib/dependencies/WorkerPlugin.js +5 -5
- package/lib/dependencies/getFunctionExpression.js +1 -1
- package/lib/esm/ModuleChunkFormatPlugin.js +5 -5
- package/lib/esm/ModuleChunkLoadingPlugin.js +2 -2
- package/lib/esm/ModuleChunkLoadingRuntimeModule.js +15 -11
- package/lib/formatLocation.js +2 -2
- package/lib/hmr/HotModuleReplacement.runtime.js +39 -27
- package/lib/hmr/JavascriptHotModuleReplacement.runtime.js +43 -32
- package/lib/hmr/JavascriptHotModuleReplacementHelper.js +1 -1
- package/lib/hmr/LazyCompilationPlugin.js +6 -6
- package/lib/hmr/lazyCompilationBackend.js +6 -6
- package/lib/ids/ChunkModuleIdRangePlugin.js +4 -4
- package/lib/ids/DeterministicChunkIdsPlugin.js +5 -4
- package/lib/ids/DeterministicModuleIdsPlugin.js +2 -2
- package/lib/ids/HashedModuleIdsPlugin.js +1 -1
- package/lib/ids/IdHelpers.js +9 -9
- package/lib/ids/NamedChunkIdsPlugin.js +5 -5
- package/lib/ids/NamedModuleIdsPlugin.js +2 -2
- package/lib/ids/NaturalChunkIdsPlugin.js +2 -2
- package/lib/ids/NaturalModuleIdsPlugin.js +1 -1
- package/lib/ids/OccurrenceChunkIdsPlugin.js +2 -2
- package/lib/ids/OccurrenceModuleIdsPlugin.js +4 -4
- package/lib/ids/SyncModuleIdsPlugin.js +4 -4
- package/lib/index.js +10 -6
- package/lib/javascript/ArrayPushCallbackChunkFormatPlugin.js +1 -1
- package/lib/javascript/BasicEvaluatedExpression.js +3 -3
- package/lib/javascript/CommonJsChunkFormatPlugin.js +1 -1
- package/lib/javascript/EnableChunkLoadingPlugin.js +1 -1
- package/lib/javascript/JavascriptGenerator.js +1 -1
- package/lib/javascript/JavascriptModulesPlugin.js +16 -16
- package/lib/javascript/JavascriptParser.js +80 -78
- package/lib/javascript/JavascriptParserHelpers.js +3 -3
- package/lib/javascript/StartupHelpers.js +2 -2
- package/lib/json/JsonGenerator.js +2 -2
- package/lib/json/JsonModulesPlugin.js +2 -2
- package/lib/library/AbstractLibraryPlugin.js +3 -3
- package/lib/library/AmdLibraryPlugin.js +3 -3
- package/lib/library/AssignLibraryPlugin.js +2 -2
- package/lib/library/EnableLibraryPlugin.js +2 -2
- package/lib/library/ModuleLibraryPlugin.js +7 -2
- package/lib/library/SystemLibraryPlugin.js +6 -4
- package/lib/library/UmdLibraryPlugin.js +14 -14
- package/lib/logging/createConsoleLogger.js +4 -4
- package/lib/logging/runtime.js +3 -3
- package/lib/logging/truncateArgs.js +4 -4
- package/lib/node/CommonJsChunkLoadingPlugin.js +2 -2
- package/lib/node/NodeEnvironmentPlugin.js +1 -1
- package/lib/node/ReadFileChunkLoadingRuntimeModule.js +16 -14
- package/lib/node/ReadFileCompileAsyncWasmPlugin.js +7 -7
- package/lib/node/ReadFileCompileWasmPlugin.js +7 -7
- package/lib/node/RequireChunkLoadingRuntimeModule.js +6 -4
- package/lib/node/nodeConsole.js +2 -2
- package/lib/optimize/AggressiveMergingPlugin.js +2 -2
- package/lib/optimize/AggressiveSplittingPlugin.js +10 -10
- package/lib/optimize/ConcatenatedModule.js +161 -52
- package/lib/optimize/EnsureChunkConditionsPlugin.js +2 -2
- package/lib/optimize/FlagIncludedChunksPlugin.js +2 -2
- package/lib/optimize/InnerGraph.js +5 -5
- package/lib/optimize/InnerGraphPlugin.js +14 -12
- package/lib/optimize/LimitChunkCountPlugin.js +5 -5
- package/lib/optimize/MangleExportsPlugin.js +5 -5
- package/lib/optimize/MergeDuplicateChunksPlugin.js +2 -2
- package/lib/optimize/MinChunkSizePlugin.js +3 -3
- package/lib/optimize/ModuleConcatenationPlugin.js +45 -38
- package/lib/optimize/RealContentHashPlugin.js +23 -23
- package/lib/optimize/RemoveEmptyChunksPlugin.js +2 -2
- package/lib/optimize/RemoveParentModulesPlugin.js +3 -3
- package/lib/optimize/RuntimeChunkPlugin.js +2 -2
- package/lib/optimize/SideEffectsFlagPlugin.js +5 -5
- package/lib/optimize/SplitChunksPlugin.js +20 -20
- package/lib/performance/AssetsOverSizeLimitWarning.js +1 -1
- package/lib/performance/EntrypointsOverSizeLimitWarning.js +2 -2
- package/lib/performance/SizeLimitsPlugin.js +4 -4
- package/lib/prefetch/ChunkPrefetchPreloadPlugin.js +1 -1
- package/lib/prefetch/ChunkPrefetchStartupRuntimeModule.js +3 -3
- package/lib/rules/BasicMatcherRulePlugin.js +1 -1
- package/lib/rules/RuleSetCompiler.js +10 -10
- package/lib/rules/UseEffectRulePlugin.js +2 -2
- package/lib/runtime/GetChunkFilenameRuntimeModule.js +15 -15
- package/lib/runtime/GetMainFilenameRuntimeModule.js +1 -1
- package/lib/runtime/GetTrustedTypesPolicyRuntimeModule.js +1 -1
- package/lib/runtime/MakeDeferredNamespaceObjectRuntime.js +1 -1
- package/lib/runtime/StartupChunkDependenciesPlugin.js +2 -2
- package/lib/runtime/StartupChunkDependenciesRuntimeModule.js +3 -3
- package/lib/schemes/DataUriPlugin.js +3 -3
- package/lib/schemes/FileUriPlugin.js +1 -1
- package/lib/schemes/HttpUriPlugin.js +40 -36
- package/lib/schemes/VirtualUrlPlugin.js +1 -1
- package/lib/serialization/BinaryMiddleware.js +11 -11
- package/lib/serialization/FileMiddleware.js +17 -17
- package/lib/serialization/ObjectMiddleware.js +8 -8
- package/lib/serialization/Serializer.js +2 -2
- package/lib/serialization/SerializerMiddleware.js +2 -2
- package/lib/sharing/ConsumeSharedPlugin.js +4 -4
- package/lib/sharing/ProvideSharedPlugin.js +4 -4
- package/lib/sharing/SharePlugin.js +1 -1
- package/lib/sharing/resolveMatchedConfigs.js +1 -1
- package/lib/stats/DefaultStatsFactoryPlugin.js +85 -80
- package/lib/stats/DefaultStatsPresetPlugin.js +15 -15
- package/lib/stats/DefaultStatsPrinterPlugin.js +87 -87
- package/lib/stats/StatsFactory.js +7 -7
- package/lib/stats/StatsPrinter.js +9 -9
- package/lib/url/URLParserPlugin.js +5 -5
- package/lib/util/AsyncQueue.js +4 -4
- package/lib/util/IterableHelpers.js +2 -2
- package/lib/util/LazyBucketSortedSet.js +3 -3
- package/lib/util/SetHelpers.js +2 -2
- package/lib/util/StackedCacheMap.js +1 -1
- package/lib/util/StackedMap.js +1 -1
- package/lib/util/TupleSet.js +1 -1
- package/lib/util/WeakTupleMap.js +1 -1
- package/lib/util/cleverMerge.js +8 -8
- package/lib/util/comparators.js +10 -10
- package/lib/util/compileBooleanMatcher.js +20 -20
- package/lib/util/concatenate.js +3 -3
- package/lib/util/conventions.js +4 -4
- package/lib/util/create-schema-validation.js +1 -1
- package/lib/util/createHash.js +1 -1
- package/lib/util/deprecation.js +4 -4
- package/lib/util/deterministicGrouping.js +7 -7
- package/lib/util/findGraphRoots.js +1 -1
- package/lib/util/fs.js +3 -3
- package/lib/util/identifier.js +14 -14
- package/lib/util/magicComment.js +5 -1
- package/lib/util/memoize.js +1 -1
- package/lib/util/processAsyncTree.js +2 -2
- package/lib/util/propertyName.js +1 -1
- package/lib/util/removeBOM.js +1 -1
- package/lib/util/runtime.js +6 -6
- package/lib/util/semver.js +16 -16
- package/lib/util/serialization.js +5 -5
- package/lib/util/smartGrouping.js +1 -1
- package/lib/validateSchema.js +2 -2
- package/lib/wasm/EnableWasmLoadingPlugin.js +1 -1
- package/lib/wasm-async/AsyncWasmLoadingRuntimeModule.js +1 -1
- package/lib/wasm-async/AsyncWebAssemblyJavascriptGenerator.js +1 -1
- package/lib/wasm-async/UniversalCompileAsyncWasmPlugin.js +4 -4
- package/lib/wasm-sync/WasmChunkLoadingRuntimeModule.js +13 -9
- package/lib/wasm-sync/WasmFinalizeExportsPlugin.js +2 -2
- package/lib/wasm-sync/WebAssemblyGenerator.js +14 -14
- package/lib/wasm-sync/WebAssemblyInInitialChunkError.js +4 -2
- package/lib/wasm-sync/WebAssemblyParser.js +2 -2
- package/lib/web/FetchCompileAsyncWasmPlugin.js +4 -4
- package/lib/web/FetchCompileWasmPlugin.js +4 -4
- package/lib/web/JsonpChunkLoadingPlugin.js +2 -2
- package/lib/web/JsonpChunkLoadingRuntimeModule.js +1 -1
- package/lib/webpack.js +17 -12
- package/lib/webworker/ImportScriptsChunkLoadingPlugin.js +2 -2
- package/lib/webworker/ImportScriptsChunkLoadingRuntimeModule.js +1 -1
- package/package.json +13 -13
- package/schemas/WebpackOptions.check.js +1 -1
- package/schemas/WebpackOptions.json +4 -0
- package/types.d.ts +151 -44
|
@@ -1874,6 +1874,10 @@
|
|
|
1874
1874
|
}
|
|
1875
1875
|
]
|
|
1876
1876
|
},
|
|
1877
|
+
"deferImport": {
|
|
1878
|
+
"description": "Enable experimental tc39 proposal https://github.com/tc39/proposal-defer-import-eval. This allows to defer execution of a module until it's first use.",
|
|
1879
|
+
"type": "boolean"
|
|
1880
|
+
},
|
|
1877
1881
|
"dynamicImportFetchPriority": {
|
|
1878
1882
|
"description": "Specifies global fetchPriority for dynamic import.",
|
|
1879
1883
|
"enum": ["low", "high", "auto", false]
|
package/types.d.ts
CHANGED
|
@@ -1180,6 +1180,7 @@ declare interface CallbackWebpack<T> {
|
|
|
1180
1180
|
(err: null | Error, stats?: T): void;
|
|
1181
1181
|
}
|
|
1182
1182
|
type Cell<T> = undefined | T;
|
|
1183
|
+
type ChildrenStatsOptions = undefined | string | boolean | StatsOptions;
|
|
1183
1184
|
declare class Chunk {
|
|
1184
1185
|
constructor(name?: null | string, backCompat?: boolean);
|
|
1185
1186
|
id: null | string | number;
|
|
@@ -1951,6 +1952,55 @@ type CodeValuePrimitive =
|
|
|
1951
1952
|
| boolean
|
|
1952
1953
|
| Function
|
|
1953
1954
|
| RegExp;
|
|
1955
|
+
declare interface Colors {
|
|
1956
|
+
reset: (value?: any) => string;
|
|
1957
|
+
bold: (value?: any) => string;
|
|
1958
|
+
dim: (value?: any) => string;
|
|
1959
|
+
italic: (value?: any) => string;
|
|
1960
|
+
underline: (value?: any) => string;
|
|
1961
|
+
inverse: (value?: any) => string;
|
|
1962
|
+
hidden: (value?: any) => string;
|
|
1963
|
+
strikethrough: (value?: any) => string;
|
|
1964
|
+
black: (value?: any) => string;
|
|
1965
|
+
red: (value?: any) => string;
|
|
1966
|
+
green: (value?: any) => string;
|
|
1967
|
+
yellow: (value?: any) => string;
|
|
1968
|
+
blue: (value?: any) => string;
|
|
1969
|
+
magenta: (value?: any) => string;
|
|
1970
|
+
cyan: (value?: any) => string;
|
|
1971
|
+
white: (value?: any) => string;
|
|
1972
|
+
gray: (value?: any) => string;
|
|
1973
|
+
bgBlack: (value?: any) => string;
|
|
1974
|
+
bgRed: (value?: any) => string;
|
|
1975
|
+
bgGreen: (value?: any) => string;
|
|
1976
|
+
bgYellow: (value?: any) => string;
|
|
1977
|
+
bgBlue: (value?: any) => string;
|
|
1978
|
+
bgMagenta: (value?: any) => string;
|
|
1979
|
+
bgCyan: (value?: any) => string;
|
|
1980
|
+
bgWhite: (value?: any) => string;
|
|
1981
|
+
blackBright: (value?: any) => string;
|
|
1982
|
+
redBright: (value?: any) => string;
|
|
1983
|
+
greenBright: (value?: any) => string;
|
|
1984
|
+
yellowBright: (value?: any) => string;
|
|
1985
|
+
blueBright: (value?: any) => string;
|
|
1986
|
+
magentaBright: (value?: any) => string;
|
|
1987
|
+
cyanBright: (value?: any) => string;
|
|
1988
|
+
whiteBright: (value?: any) => string;
|
|
1989
|
+
bgBlackBright: (value?: any) => string;
|
|
1990
|
+
bgRedBright: (value?: any) => string;
|
|
1991
|
+
bgGreenBright: (value?: any) => string;
|
|
1992
|
+
bgYellowBright: (value?: any) => string;
|
|
1993
|
+
bgBlueBright: (value?: any) => string;
|
|
1994
|
+
bgMagentaBright: (value?: any) => string;
|
|
1995
|
+
bgCyanBright: (value?: any) => string;
|
|
1996
|
+
bgWhiteBright: (value?: any) => string;
|
|
1997
|
+
}
|
|
1998
|
+
declare interface ColorsOptions {
|
|
1999
|
+
/**
|
|
2000
|
+
* force use colors
|
|
2001
|
+
*/
|
|
2002
|
+
useColor?: boolean;
|
|
2003
|
+
}
|
|
1954
2004
|
declare interface Comparator<T> {
|
|
1955
2005
|
(a: T, b: T): 0 | 1 | -1;
|
|
1956
2006
|
}
|
|
@@ -2519,7 +2569,7 @@ declare interface CompilationHooksJavascriptModulesPlugin {
|
|
|
2519
2569
|
renderStartup: SyncWaterfallHook<[Source, Module, StartupRenderContext]>;
|
|
2520
2570
|
renderRequire: SyncWaterfallHook<[string, RenderBootstrapContext]>;
|
|
2521
2571
|
inlineInRuntimeBailout: SyncBailHook<
|
|
2522
|
-
[Module, RenderBootstrapContext],
|
|
2572
|
+
[Module, Partial<RenderBootstrapContext>],
|
|
2523
2573
|
string | void
|
|
2524
2574
|
>;
|
|
2525
2575
|
embedInRuntimeBailout: SyncBailHook<
|
|
@@ -2701,6 +2751,7 @@ declare interface ConcatenatedModuleInfo {
|
|
|
2701
2751
|
rawExportMap?: Map<string, string>;
|
|
2702
2752
|
namespaceExportSymbol?: string;
|
|
2703
2753
|
namespaceObjectName?: string;
|
|
2754
|
+
concatenationScope?: ConcatenationScope;
|
|
2704
2755
|
|
|
2705
2756
|
/**
|
|
2706
2757
|
* "default-with-named" namespace
|
|
@@ -2746,12 +2797,17 @@ declare interface ConcatenationBailoutReasonContext {
|
|
|
2746
2797
|
declare class ConcatenationScope {
|
|
2747
2798
|
constructor(
|
|
2748
2799
|
modulesMap: ModuleInfo[] | Map<Module, ModuleInfo>,
|
|
2749
|
-
currentModule: ConcatenatedModuleInfo
|
|
2800
|
+
currentModule: ConcatenatedModuleInfo,
|
|
2801
|
+
usedNames: Set<string>
|
|
2750
2802
|
);
|
|
2803
|
+
usedNames: Set<string>;
|
|
2751
2804
|
isModuleInScope(module: Module): boolean;
|
|
2752
2805
|
registerExport(exportName: string, symbol: string): void;
|
|
2753
2806
|
registerRawExport(exportName: string, expression: string): void;
|
|
2807
|
+
getRawExport(exportName: string): undefined | string;
|
|
2808
|
+
setRawExportMap(exportName: string, expression: string): void;
|
|
2754
2809
|
registerNamespaceExport(symbol: string): void;
|
|
2810
|
+
registerUsedName(symbol: string): boolean;
|
|
2755
2811
|
createModuleReference(
|
|
2756
2812
|
module: Module,
|
|
2757
2813
|
__1: Partial<ModuleReferenceOptions>
|
|
@@ -5180,6 +5236,7 @@ declare class ExternalModule extends Module {
|
|
|
5180
5236
|
unsafeCacheData: UnsafeCacheData,
|
|
5181
5237
|
normalModuleFactory: NormalModuleFactory
|
|
5182
5238
|
): void;
|
|
5239
|
+
static ModuleExternalInitFragment: typeof ModuleExternalInitFragment;
|
|
5183
5240
|
}
|
|
5184
5241
|
declare interface ExternalModuleInfo {
|
|
5185
5242
|
type: "external";
|
|
@@ -5606,9 +5663,9 @@ declare abstract class FileSystemInfo {
|
|
|
5606
5663
|
): void;
|
|
5607
5664
|
createSnapshot(
|
|
5608
5665
|
startTime: undefined | null | number,
|
|
5609
|
-
files: null | Iterable<string>,
|
|
5610
|
-
directories: null | Iterable<string>,
|
|
5611
|
-
missing: null | Iterable<string>,
|
|
5666
|
+
files: undefined | null | Iterable<string>,
|
|
5667
|
+
directories: undefined | null | Iterable<string>,
|
|
5668
|
+
missing: undefined | null | Iterable<string>,
|
|
5612
5669
|
options: undefined | null | SnapshotOptionsFileSystemInfo,
|
|
5613
5670
|
callback: (err: null | WebpackError, snapshot: null | Snapshot) => void
|
|
5614
5671
|
): void;
|
|
@@ -5910,10 +5967,12 @@ declare class HarmonyImportDependency extends ModuleDependency {
|
|
|
5910
5967
|
constructor(
|
|
5911
5968
|
request: string,
|
|
5912
5969
|
sourceOrder: number,
|
|
5913
|
-
attributes?: ImportAttributes
|
|
5970
|
+
attributes?: ImportAttributes,
|
|
5971
|
+
defer?: boolean
|
|
5914
5972
|
);
|
|
5915
5973
|
sourceOrder: number;
|
|
5916
5974
|
getImportVar(moduleGraph: ModuleGraph): string;
|
|
5975
|
+
getModuleExports(__0: DependencyTemplateContext): string;
|
|
5917
5976
|
getImportStatement(
|
|
5918
5977
|
update: boolean,
|
|
5919
5978
|
__1: DependencyTemplateContext
|
|
@@ -6226,6 +6285,7 @@ type ImportSource =
|
|
|
6226
6285
|
| SimpleLiteral
|
|
6227
6286
|
| RegExpLiteral
|
|
6228
6287
|
| BigIntLiteral;
|
|
6288
|
+
type Imported = true | [string, string][];
|
|
6229
6289
|
|
|
6230
6290
|
/**
|
|
6231
6291
|
* Options for infrastructure level logging.
|
|
@@ -6288,6 +6348,8 @@ declare class InitFragment<GenerateContext> {
|
|
|
6288
6348
|
serialize(context: ObjectSerializerContext): void;
|
|
6289
6349
|
deserialize(context: ObjectDeserializerContext): void;
|
|
6290
6350
|
merge: any;
|
|
6351
|
+
getImported: any;
|
|
6352
|
+
setImported: any;
|
|
6291
6353
|
static addToSource<Context, T>(
|
|
6292
6354
|
source: Source,
|
|
6293
6355
|
initFragments: InitFragment<T>[],
|
|
@@ -7818,6 +7880,11 @@ declare interface JavascriptParserOptions {
|
|
|
7818
7880
|
*/
|
|
7819
7881
|
createRequire?: string | boolean;
|
|
7820
7882
|
|
|
7883
|
+
/**
|
|
7884
|
+
* Enable experimental tc39 proposal https://github.com/tc39/proposal-defer-import-eval. This allows to defer execution of a module until it's first use.
|
|
7885
|
+
*/
|
|
7886
|
+
deferImport?: boolean;
|
|
7887
|
+
|
|
7821
7888
|
/**
|
|
7822
7889
|
* Specifies global fetchPriority for dynamic import.
|
|
7823
7890
|
*/
|
|
@@ -8445,7 +8512,7 @@ declare interface KnownStatsChunkOrigin {
|
|
|
8445
8512
|
moduleId?: string | number;
|
|
8446
8513
|
}
|
|
8447
8514
|
declare interface KnownStatsCompilation {
|
|
8448
|
-
env?:
|
|
8515
|
+
env?: any;
|
|
8449
8516
|
name?: string;
|
|
8450
8517
|
hash?: string;
|
|
8451
8518
|
version?: string;
|
|
@@ -9759,6 +9826,28 @@ declare class ModuleDependency extends Dependency {
|
|
|
9759
9826
|
static EXPORTS_OBJECT_REFERENCED: string[][];
|
|
9760
9827
|
static TRANSITIVE: typeof TRANSITIVE;
|
|
9761
9828
|
}
|
|
9829
|
+
declare class ModuleExternalInitFragment extends InitFragment<GenerateContext> {
|
|
9830
|
+
constructor(
|
|
9831
|
+
request: string,
|
|
9832
|
+
imported: Imported,
|
|
9833
|
+
ident?: string,
|
|
9834
|
+
dependencyMeta?: ImportDependencyMeta,
|
|
9835
|
+
hashFunction?: string | typeof Hash
|
|
9836
|
+
);
|
|
9837
|
+
getNamespaceIdentifier(): string;
|
|
9838
|
+
static addToSource<Context, T>(
|
|
9839
|
+
source: Source,
|
|
9840
|
+
initFragments: InitFragment<T>[],
|
|
9841
|
+
context: Context
|
|
9842
|
+
): Source;
|
|
9843
|
+
static STAGE_CONSTANTS: number;
|
|
9844
|
+
static STAGE_ASYNC_BOUNDARY: number;
|
|
9845
|
+
static STAGE_HARMONY_EXPORTS: number;
|
|
9846
|
+
static STAGE_HARMONY_IMPORTS: number;
|
|
9847
|
+
static STAGE_PROVIDES: number;
|
|
9848
|
+
static STAGE_ASYNC_DEPENDENCIES: number;
|
|
9849
|
+
static STAGE_ASYNC_HARMONY_IMPORTS: number;
|
|
9850
|
+
}
|
|
9762
9851
|
declare abstract class ModuleFactory {
|
|
9763
9852
|
create(
|
|
9764
9853
|
data: ModuleFactoryCreateData,
|
|
@@ -10417,14 +10506,18 @@ declare interface MultiCompilerOptions {
|
|
|
10417
10506
|
*/
|
|
10418
10507
|
parallelism?: number;
|
|
10419
10508
|
}
|
|
10509
|
+
type MultiConfiguration = ReadonlyArray<Configuration> & MultiCompilerOptions;
|
|
10420
10510
|
declare abstract class MultiStats {
|
|
10421
10511
|
stats: Stats[];
|
|
10422
10512
|
get hash(): string;
|
|
10423
10513
|
hasErrors(): boolean;
|
|
10424
10514
|
hasWarnings(): boolean;
|
|
10425
|
-
toJson(options?: string | boolean |
|
|
10426
|
-
toString(options?: string | boolean |
|
|
10515
|
+
toJson(options?: string | boolean | MultiStatsOptions): StatsCompilation;
|
|
10516
|
+
toString(options?: string | boolean | MultiStatsOptions): string;
|
|
10427
10517
|
}
|
|
10518
|
+
type MultiStatsOptions = Omit<StatsOptions, "children"> & {
|
|
10519
|
+
children?: string | boolean | StatsOptions | ChildrenStatsOptions[];
|
|
10520
|
+
};
|
|
10428
10521
|
declare abstract class MultiWatching {
|
|
10429
10522
|
watchings: Watching[];
|
|
10430
10523
|
compiler: MultiCompiler;
|
|
@@ -10877,43 +10970,43 @@ declare class NormalModuleReplacementPlugin {
|
|
|
10877
10970
|
type NormalizedStatsOptions = KnownNormalizedStatsOptions &
|
|
10878
10971
|
Omit<
|
|
10879
10972
|
StatsOptions,
|
|
10880
|
-
| "context"
|
|
10881
|
-
| "chunkGroups"
|
|
10882
|
-
| "requestShortener"
|
|
10883
|
-
| "chunksSort"
|
|
10884
|
-
| "modulesSort"
|
|
10885
|
-
| "chunkModulesSort"
|
|
10886
|
-
| "nestedModulesSort"
|
|
10887
10973
|
| "assetsSort"
|
|
10888
|
-
| "ids"
|
|
10889
|
-
| "cachedAssets"
|
|
10890
|
-
| "groupAssetsByEmitStatus"
|
|
10891
|
-
| "groupAssetsByPath"
|
|
10892
|
-
| "groupAssetsByExtension"
|
|
10893
10974
|
| "assetsSpace"
|
|
10894
|
-
| "
|
|
10895
|
-
| "excludeModules"
|
|
10896
|
-
| "warningsFilter"
|
|
10975
|
+
| "cachedAssets"
|
|
10897
10976
|
| "cachedModules"
|
|
10898
|
-
| "
|
|
10977
|
+
| "chunkGroupAuxiliary"
|
|
10978
|
+
| "chunkGroupChildren"
|
|
10979
|
+
| "chunkGroupMaxAssets"
|
|
10980
|
+
| "chunkGroups"
|
|
10981
|
+
| "chunkModulesSpace"
|
|
10982
|
+
| "chunksSort"
|
|
10983
|
+
| "context"
|
|
10899
10984
|
| "dependentModules"
|
|
10900
|
-
| "
|
|
10985
|
+
| "entrypoints"
|
|
10986
|
+
| "excludeAssets"
|
|
10987
|
+
| "excludeModules"
|
|
10988
|
+
| "groupAssetsByEmitStatus"
|
|
10989
|
+
| "groupAssetsByExtension"
|
|
10990
|
+
| "groupAssetsByPath"
|
|
10991
|
+
| "groupModulesByAttributes"
|
|
10901
10992
|
| "groupModulesByCacheStatus"
|
|
10993
|
+
| "groupModulesByExtension"
|
|
10902
10994
|
| "groupModulesByLayer"
|
|
10903
|
-
| "groupModulesByAttributes"
|
|
10904
10995
|
| "groupModulesByPath"
|
|
10905
|
-
| "groupModulesByExtension"
|
|
10906
10996
|
| "groupModulesByType"
|
|
10907
|
-
| "
|
|
10908
|
-
| "chunkGroupAuxiliary"
|
|
10909
|
-
| "chunkGroupChildren"
|
|
10910
|
-
| "chunkGroupMaxAssets"
|
|
10911
|
-
| "modulesSpace"
|
|
10912
|
-
| "chunkModulesSpace"
|
|
10913
|
-
| "nestedModulesSpace"
|
|
10997
|
+
| "ids"
|
|
10914
10998
|
| "logging"
|
|
10915
10999
|
| "loggingDebug"
|
|
10916
11000
|
| "loggingTrace"
|
|
11001
|
+
| "modulesSort"
|
|
11002
|
+
| "modulesSpace"
|
|
11003
|
+
| "nestedModulesSpace"
|
|
11004
|
+
| "orphanModules"
|
|
11005
|
+
| "runtimeModules"
|
|
11006
|
+
| "warningsFilter"
|
|
11007
|
+
| "requestShortener"
|
|
11008
|
+
| "chunkModulesSort"
|
|
11009
|
+
| "nestedModulesSort"
|
|
10917
11010
|
| "_env"
|
|
10918
11011
|
> &
|
|
10919
11012
|
Record<string, any>;
|
|
@@ -12574,7 +12667,7 @@ declare class ProgressPlugin {
|
|
|
12574
12667
|
showModules?: boolean;
|
|
12575
12668
|
showDependencies?: boolean;
|
|
12576
12669
|
showActiveModules?: boolean;
|
|
12577
|
-
percentBy?: null | "
|
|
12670
|
+
percentBy?: null | "modules" | "entries" | "dependencies";
|
|
12578
12671
|
apply(compiler: Compiler | MultiCompiler): void;
|
|
12579
12672
|
static getReporter(
|
|
12580
12673
|
compiler: Compiler
|
|
@@ -12639,7 +12732,7 @@ declare interface ProgressPluginOptions {
|
|
|
12639
12732
|
/**
|
|
12640
12733
|
* Collect percent algorithm. By default it calculates by a median from modules, entries and dependencies percent.
|
|
12641
12734
|
*/
|
|
12642
|
-
percentBy?: null | "
|
|
12735
|
+
percentBy?: null | "modules" | "entries" | "dependencies";
|
|
12643
12736
|
|
|
12644
12737
|
/**
|
|
12645
12738
|
* Collect profile data for progress steps. Default: false.
|
|
@@ -14912,6 +15005,7 @@ declare abstract class RuntimeTemplate {
|
|
|
14912
15005
|
supportsEcmaScriptModuleSyntax(): undefined | boolean;
|
|
14913
15006
|
supportTemplateLiteral(): undefined | boolean;
|
|
14914
15007
|
supportNodePrefixForCoreModules(): undefined | boolean;
|
|
15008
|
+
renderNodePrefixForCoreModule(mod: string): string;
|
|
14915
15009
|
returningFunction(returnValue: string, args?: string): string;
|
|
14916
15010
|
basicFunction(args: string, body: string | string[]): string;
|
|
14917
15011
|
concatenation(...args: (string | { expr: string })[]): string;
|
|
@@ -17389,21 +17483,24 @@ declare interface WriteStreamOptions {
|
|
|
17389
17483
|
declare function exports(
|
|
17390
17484
|
options: Configuration,
|
|
17391
17485
|
callback?: CallbackWebpack<Stats>
|
|
17392
|
-
): Compiler;
|
|
17486
|
+
): null | Compiler;
|
|
17393
17487
|
declare function exports(
|
|
17394
|
-
options:
|
|
17488
|
+
options: MultiConfiguration,
|
|
17395
17489
|
callback?: CallbackWebpack<MultiStats>
|
|
17396
|
-
): MultiCompiler;
|
|
17490
|
+
): null | MultiCompiler;
|
|
17397
17491
|
declare namespace exports {
|
|
17398
17492
|
export const webpack: {
|
|
17399
|
-
(options: Configuration, callback?: CallbackWebpack<Stats>): Compiler;
|
|
17400
17493
|
(
|
|
17401
|
-
options:
|
|
17494
|
+
options: Configuration,
|
|
17495
|
+
callback?: CallbackWebpack<Stats>
|
|
17496
|
+
): null | Compiler;
|
|
17497
|
+
(
|
|
17498
|
+
options: MultiConfiguration,
|
|
17402
17499
|
callback?: CallbackWebpack<MultiStats>
|
|
17403
|
-
): MultiCompiler;
|
|
17500
|
+
): null | MultiCompiler;
|
|
17404
17501
|
};
|
|
17405
17502
|
export const validate: (
|
|
17406
|
-
configuration: Configuration |
|
|
17503
|
+
configuration: Configuration | MultiConfiguration
|
|
17407
17504
|
) => void;
|
|
17408
17505
|
export const validateSchema: (
|
|
17409
17506
|
schema: Parameters<typeof validateFunction>[0],
|
|
@@ -17412,6 +17509,7 @@ declare namespace exports {
|
|
|
17412
17509
|
) => void;
|
|
17413
17510
|
export const version: string;
|
|
17414
17511
|
export namespace cli {
|
|
17512
|
+
export let createColors: (__0?: ColorsOptions) => Colors;
|
|
17415
17513
|
export let getArguments: (
|
|
17416
17514
|
schema?:
|
|
17417
17515
|
| (JSONSchema4 & {
|
|
@@ -17448,6 +17546,7 @@ declare namespace exports {
|
|
|
17448
17546
|
};
|
|
17449
17547
|
})
|
|
17450
17548
|
) => Flags;
|
|
17549
|
+
export let isColorSupported: () => boolean;
|
|
17451
17550
|
export let processArguments: (
|
|
17452
17551
|
args: Flags,
|
|
17453
17552
|
config: ObjectConfiguration,
|
|
@@ -17525,6 +17624,10 @@ declare namespace exports {
|
|
|
17525
17624
|
export let ensureChunkHandlers: "__webpack_require__.f";
|
|
17526
17625
|
export let ensureChunkIncludeEntries: "__webpack_require__.f (include entries)";
|
|
17527
17626
|
export let entryModuleId: "__webpack_require__.s";
|
|
17627
|
+
export let esmId: "__webpack_esm_id__";
|
|
17628
|
+
export let esmIds: "__webpack_esm_ids__";
|
|
17629
|
+
export let esmModules: "__webpack_esm_modules__";
|
|
17630
|
+
export let esmRuntime: "__webpack_esm_runtime__";
|
|
17528
17631
|
export let exports: "__webpack_exports__";
|
|
17529
17632
|
export let externalInstallChunk: "__webpack_require__.C";
|
|
17530
17633
|
export let getChunkCssFilename: "__webpack_require__.k";
|
|
@@ -18100,7 +18203,9 @@ declare namespace exports {
|
|
|
18100
18203
|
AssetEmittedInfo,
|
|
18101
18204
|
Entrypoint,
|
|
18102
18205
|
MultiCompilerOptions,
|
|
18206
|
+
MultiConfiguration,
|
|
18103
18207
|
MultiStats,
|
|
18208
|
+
MultiStatsOptions,
|
|
18104
18209
|
ResolveData,
|
|
18105
18210
|
ParserState,
|
|
18106
18211
|
ResolvePluginInstance,
|
|
@@ -18108,6 +18213,8 @@ declare namespace exports {
|
|
|
18108
18213
|
Watching,
|
|
18109
18214
|
Argument,
|
|
18110
18215
|
Problem,
|
|
18216
|
+
Colors,
|
|
18217
|
+
ColorsOptions,
|
|
18111
18218
|
StatsAsset,
|
|
18112
18219
|
StatsChunk,
|
|
18113
18220
|
StatsChunkGroup,
|