webpack 5.59.0 → 5.62.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.

Potentially problematic release.


This version of webpack might be problematic. Click here for more details.

Files changed (44) hide show
  1. package/hot/lazy-compilation-node.js +3 -1
  2. package/lib/Chunk.js +3 -2
  3. package/lib/Compilation.js +29 -16
  4. package/lib/Compiler.js +13 -11
  5. package/lib/FileSystemInfo.js +2 -2
  6. package/lib/HotModuleReplacementPlugin.js +3 -1
  7. package/lib/NormalModule.js +9 -3
  8. package/lib/WebpackOptionsApply.js +12 -9
  9. package/lib/cache/PackFileCacheStrategy.js +7 -4
  10. package/lib/config/defaults.js +4 -6
  11. package/lib/dependencies/AMDRequireDependency.js +6 -6
  12. package/lib/dependencies/CommonJsFullRequireDependency.js +5 -1
  13. package/lib/dependencies/CommonJsImportsParserPlugin.js +3 -1
  14. package/lib/dependencies/CommonJsRequireContextDependency.js +5 -1
  15. package/lib/dependencies/ContextDependency.js +1 -0
  16. package/lib/dependencies/ContextDependencyTemplateAsRequireCall.js +4 -1
  17. package/lib/dependencies/HarmonyExportDependencyParserPlugin.js +12 -3
  18. package/lib/dependencies/HarmonyExportImportedSpecifierDependency.js +25 -17
  19. package/lib/dependencies/HarmonyImportDependency.js +21 -0
  20. package/lib/dependencies/HarmonyImportDependencyParserPlugin.js +17 -4
  21. package/lib/dependencies/HarmonyImportSpecifierDependency.js +24 -14
  22. package/lib/dependencies/RequireEnsureDependency.js +2 -2
  23. package/lib/hmr/LazyCompilationPlugin.js +9 -5
  24. package/lib/hmr/lazyCompilationBackend.js +47 -10
  25. package/lib/node/NodeTargetPlugin.js +2 -0
  26. package/lib/node/RequireChunkLoadingRuntimeModule.js +1 -1
  27. package/lib/optimize/ModuleConcatenationPlugin.js +5 -2
  28. package/lib/optimize/SplitChunksPlugin.js +8 -1
  29. package/lib/runtime/AsyncModuleRuntimeModule.js +2 -2
  30. package/lib/schemes/HttpUriPlugin.js +1 -0
  31. package/lib/sharing/ConsumeSharedRuntimeModule.js +1 -1
  32. package/lib/sharing/ShareRuntimeModule.js +1 -1
  33. package/lib/util/createHash.js +12 -0
  34. package/lib/util/deprecation.js +10 -2
  35. package/lib/util/hash/BatchedHash.js +7 -4
  36. package/lib/util/hash/md4.js +20 -0
  37. package/lib/util/hash/wasm-hash.js +163 -0
  38. package/lib/util/hash/xxhash64.js +5 -139
  39. package/lib/webpack.js +1 -2
  40. package/module.d.ts +200 -0
  41. package/package.json +12 -10
  42. package/schemas/WebpackOptions.check.js +1 -1
  43. package/schemas/WebpackOptions.json +117 -27
  44. package/types.d.ts +73 -22
@@ -681,14 +681,14 @@
681
681
  "implements": ["#/definitions/ExperimentsCommon"],
682
682
  "additionalProperties": false,
683
683
  "properties": {
684
- "asset": {
685
- "description": "Allow module type 'asset' to generate assets.",
686
- "type": "boolean"
687
- },
688
684
  "asyncWebAssembly": {
689
685
  "description": "Support WebAssembly as asynchronous EcmaScript Module.",
690
686
  "type": "boolean"
691
687
  },
688
+ "backCompat": {
689
+ "description": "Enable backward-compat layer with deprecation warnings for many webpack 4 APIs.",
690
+ "type": "boolean"
691
+ },
692
692
  "buildHttp": {
693
693
  "description": "Build http(s): urls using a lockfile and resource content cache.",
694
694
  "anyOf": [
@@ -709,7 +709,7 @@
709
709
  "type": "boolean"
710
710
  },
711
711
  "layers": {
712
- "description": "Enable module and chunk layers.",
712
+ "description": "Enable module layers.",
713
713
  "type": "boolean"
714
714
  },
715
715
  "lazyCompilation": {
@@ -742,14 +742,14 @@
742
742
  "type": "object",
743
743
  "additionalProperties": false,
744
744
  "properties": {
745
- "asset": {
746
- "description": "Allow module type 'asset' to generate assets.",
747
- "type": "boolean"
748
- },
749
745
  "asyncWebAssembly": {
750
746
  "description": "Support WebAssembly as asynchronous EcmaScript Module.",
751
747
  "type": "boolean"
752
748
  },
749
+ "backCompat": {
750
+ "description": "Enable backward-compat layer with deprecation warnings for many webpack 4 APIs.",
751
+ "type": "boolean"
752
+ },
753
753
  "cacheUnaffected": {
754
754
  "description": "Enable additional in memory caching of modules that are unchanged and reference only unchanged modules.",
755
755
  "type": "boolean"
@@ -759,7 +759,7 @@
759
759
  "type": "boolean"
760
760
  },
761
761
  "layers": {
762
- "description": "Enable module and chunk layers.",
762
+ "description": "Enable module layers.",
763
763
  "type": "boolean"
764
764
  },
765
765
  "outputModule": {
@@ -782,14 +782,14 @@
782
782
  "implements": ["#/definitions/ExperimentsCommon"],
783
783
  "additionalProperties": false,
784
784
  "properties": {
785
- "asset": {
786
- "description": "Allow module type 'asset' to generate assets.",
787
- "type": "boolean"
788
- },
789
785
  "asyncWebAssembly": {
790
786
  "description": "Support WebAssembly as asynchronous EcmaScript Module.",
791
787
  "type": "boolean"
792
788
  },
789
+ "backCompat": {
790
+ "description": "Enable backward-compat layer with deprecation warnings for many webpack 4 APIs.",
791
+ "type": "boolean"
792
+ },
793
793
  "buildHttp": {
794
794
  "description": "Build http(s): urls using a lockfile and resource content cache.",
795
795
  "oneOf": [
@@ -807,7 +807,7 @@
807
807
  "type": "boolean"
808
808
  },
809
809
  "layers": {
810
- "description": "Enable module and chunk layers.",
810
+ "description": "Enable module layers.",
811
811
  "type": "boolean"
812
812
  },
813
813
  "lazyCompilation": {
@@ -1068,12 +1068,12 @@
1068
1068
  "description": "List of paths that are managed by a package manager and contain a version or hash in its path so all files are immutable.",
1069
1069
  "anyOf": [
1070
1070
  {
1071
- "description": "A RegExp matching a immutable directory (usually a package manager cache directory, including the tailing slash)",
1071
+ "description": "A RegExp matching an immutable directory (usually a package manager cache directory, including the tailing slash)",
1072
1072
  "instanceof": "RegExp",
1073
1073
  "tsType": "RegExp"
1074
1074
  },
1075
1075
  {
1076
- "description": "A path to a immutable directory (usually a package manager cache directory).",
1076
+ "description": "A path to an immutable directory (usually a package manager cache directory).",
1077
1077
  "type": "string",
1078
1078
  "absolutePath": true,
1079
1079
  "minLength": 1
@@ -1474,6 +1474,10 @@
1474
1474
  "description": "Enable/disable parsing of magic comments in CommonJs syntax.",
1475
1475
  "type": "boolean"
1476
1476
  },
1477
+ "exportsPresence": {
1478
+ "description": "Specifies the behavior of invalid export names in \"import ... from ...\" and \"export ... from ...\".",
1479
+ "enum": ["error", "warn", "auto", false]
1480
+ },
1477
1481
  "exprContextCritical": {
1478
1482
  "description": "Enable warnings for full dynamic dependencies.",
1479
1483
  "type": "boolean"
@@ -1506,9 +1510,17 @@
1506
1510
  "description": "Enable/disable parsing of import() syntax.",
1507
1511
  "type": "boolean"
1508
1512
  },
1513
+ "importExportsPresence": {
1514
+ "description": "Specifies the behavior of invalid export names in \"import ... from ...\".",
1515
+ "enum": ["error", "warn", "auto", false]
1516
+ },
1509
1517
  "node": {
1510
1518
  "$ref": "#/definitions/Node"
1511
1519
  },
1520
+ "reexportExportsPresence": {
1521
+ "description": "Specifies the behavior of invalid export names in \"export ... from ...\". This might be useful to disable during the migration from \"export ... from ...\" to \"export type ... from ...\" when reexporting types in TypeScript.",
1522
+ "enum": ["error", "warn", "auto", false]
1523
+ },
1512
1524
  "requireContext": {
1513
1525
  "description": "Enable/disable parsing of require.context syntax.",
1514
1526
  "type": "boolean"
@@ -1526,7 +1538,7 @@
1526
1538
  "type": "boolean"
1527
1539
  },
1528
1540
  "strictExportPresence": {
1529
- "description": "Emit errors instead of warnings when imported names don't exist in imported module.",
1541
+ "description": "Deprecated in favor of \"exportsPresence\". Emit errors instead of warnings when imported names don't exist in imported module.",
1530
1542
  "type": "boolean"
1531
1543
  },
1532
1544
  "strictThisContextOnImports": {
@@ -1615,20 +1627,86 @@
1615
1627
  }
1616
1628
  ]
1617
1629
  },
1618
- "LazyCompilationOptions": {
1619
- "description": "Options for compiling entrypoints and import()s only when they are accessed.",
1630
+ "LazyCompilationDefaultBackendOptions": {
1631
+ "description": "Options for the default backend.",
1620
1632
  "type": "object",
1621
1633
  "additionalProperties": false,
1622
1634
  "properties": {
1623
- "backend": {
1624
- "description": "A custom backend.",
1625
- "instanceof": "Function",
1626
- "tsType": "(((compiler: import('../lib/Compiler'), client: string, callback: (err?: Error, api?: any) => void) => void) | ((compiler: import('../lib/Compiler'), client: string) => Promise<any>))"
1627
- },
1628
1635
  "client": {
1629
1636
  "description": "A custom client.",
1630
1637
  "type": "string"
1631
1638
  },
1639
+ "listen": {
1640
+ "description": "Specifies where to listen to from the server.",
1641
+ "anyOf": [
1642
+ {
1643
+ "description": "A port.",
1644
+ "type": "number"
1645
+ },
1646
+ {
1647
+ "description": "Listen options.",
1648
+ "type": "object",
1649
+ "additionalProperties": true,
1650
+ "properties": {
1651
+ "host": {
1652
+ "description": "A host.",
1653
+ "type": "string"
1654
+ },
1655
+ "port": {
1656
+ "description": "A port.",
1657
+ "type": "number"
1658
+ }
1659
+ },
1660
+ "tsType": "import(\"net\").ListenOptions"
1661
+ },
1662
+ {
1663
+ "description": "A custom listen function.",
1664
+ "instanceof": "Function",
1665
+ "tsType": "((server: import(\"net\").Server) => void)"
1666
+ }
1667
+ ]
1668
+ },
1669
+ "protocol": {
1670
+ "description": "Specifies the protocol the client should use to connect to the server.",
1671
+ "enum": ["http", "https"]
1672
+ },
1673
+ "server": {
1674
+ "description": "Specifies how to create the server handling the EventSource requests.",
1675
+ "anyOf": [
1676
+ {
1677
+ "description": "ServerOptions for the http or https createServer call.",
1678
+ "type": "object",
1679
+ "additionalProperties": true,
1680
+ "properties": {},
1681
+ "tsType": "(import(\"https\").ServerOptions | import(\"http\").ServerOptions)"
1682
+ },
1683
+ {
1684
+ "description": "A custom create server function.",
1685
+ "instanceof": "Function",
1686
+ "tsType": "(() => import(\"net\").Server)"
1687
+ }
1688
+ ]
1689
+ }
1690
+ }
1691
+ },
1692
+ "LazyCompilationOptions": {
1693
+ "description": "Options for compiling entrypoints and import()s only when they are accessed.",
1694
+ "type": "object",
1695
+ "additionalProperties": false,
1696
+ "properties": {
1697
+ "backend": {
1698
+ "description": "Specifies the backend that should be used for handling client keep alive.",
1699
+ "anyOf": [
1700
+ {
1701
+ "description": "A custom backend.",
1702
+ "instanceof": "Function",
1703
+ "tsType": "(((compiler: import('../lib/Compiler'), callback: (err?: Error, api?: import(\"../lib/hmr/LazyCompilationPlugin\").BackendApi) => void) => void) | ((compiler: import('../lib/Compiler')) => Promise<import(\"../lib/hmr/LazyCompilationPlugin\").BackendApi>))"
1704
+ },
1705
+ {
1706
+ "$ref": "#/definitions/LazyCompilationDefaultBackendOptions"
1707
+ }
1708
+ ]
1709
+ },
1632
1710
  "entries": {
1633
1711
  "description": "Enable/disable lazy compilation for entries.",
1634
1712
  "type": "boolean"
@@ -2631,6 +2709,18 @@
2631
2709
  "type": "string",
2632
2710
  "minLength": 1
2633
2711
  },
2712
+ "chunks": {
2713
+ "description": "Select chunks for determining shared modules (defaults to \"async\", \"initial\" and \"all\" requires adding these chunks to the HTML).",
2714
+ "anyOf": [
2715
+ {
2716
+ "enum": ["initial", "async", "all"]
2717
+ },
2718
+ {
2719
+ "instanceof": "Function",
2720
+ "tsType": "((chunk: import('../lib/Chunk')) => boolean)"
2721
+ }
2722
+ ]
2723
+ },
2634
2724
  "maxAsyncSize": {
2635
2725
  "description": "Maximal size hint for the on-demand chunks.",
2636
2726
  "oneOf": [
@@ -4138,12 +4228,12 @@
4138
4228
  "description": "List of paths that are managed by a package manager and contain a version or hash in its path so all files are immutable.",
4139
4229
  "anyOf": [
4140
4230
  {
4141
- "description": "A RegExp matching a immutable directory (usually a package manager cache directory, including the tailing slash)",
4231
+ "description": "A RegExp matching an immutable directory (usually a package manager cache directory, including the tailing slash)",
4142
4232
  "instanceof": "RegExp",
4143
4233
  "tsType": "RegExp"
4144
4234
  },
4145
4235
  {
4146
- "description": "A path to a immutable directory (usually a package manager cache directory).",
4236
+ "description": "A path to an immutable directory (usually a package manager cache directory).",
4147
4237
  "type": "string",
4148
4238
  "absolutePath": true,
4149
4239
  "minLength": 1
package/types.d.ts CHANGED
@@ -80,6 +80,8 @@ import {
80
80
  WithStatement,
81
81
  YieldExpression
82
82
  } from "estree";
83
+ import { ServerOptions as ServerOptionsImport } from "http";
84
+ import { ListenOptions, Server } from "net";
83
85
  import { validate as validateFunction } from "schema-utils";
84
86
  import { default as ValidationError } from "schema-utils/declarations/ValidationError";
85
87
  import { ValidationErrorConfiguration } from "schema-utils/declarations/validate";
@@ -95,6 +97,7 @@ import {
95
97
  SyncHook,
96
98
  SyncWaterfallHook
97
99
  } from "tapable";
100
+ import { SecureContextOptions, TlsOptions } from "tls";
98
101
 
99
102
  declare class AbstractLibraryPlugin<T> {
100
103
  constructor(__0: {
@@ -383,6 +386,10 @@ declare class AutomaticPrefetchPlugin {
383
386
  apply(compiler: Compiler): void;
384
387
  }
385
388
  type AuxiliaryComment = string | LibraryCustomUmdCommentObject;
389
+ declare interface BackendApi {
390
+ dispose: (arg0?: Error) => void;
391
+ module: (arg0: Module) => { client: string; data: string; active: boolean };
392
+ }
386
393
  declare class BannerPlugin {
387
394
  constructor(options: BannerPluginArgument);
388
395
  options: BannerPluginOptions;
@@ -684,7 +691,7 @@ declare interface CallbackWebpack<T> {
684
691
  }
685
692
  type Cell<T> = undefined | T;
686
693
  declare class Chunk {
687
- constructor(name?: string);
694
+ constructor(name?: string, backCompat?: boolean);
688
695
  id: null | string | number;
689
696
  ids: null | (string | number)[];
690
697
  debugId: number;
@@ -1386,22 +1393,22 @@ declare class Compilation {
1386
1393
  additionalChunkAssets: FakeHook<
1387
1394
  Pick<
1388
1395
  AsyncSeriesHook<[Set<Chunk>]>,
1389
- "tap" | "tapAsync" | "tapPromise" | "name"
1396
+ "name" | "tap" | "tapAsync" | "tapPromise"
1390
1397
  >
1391
1398
  >;
1392
1399
  additionalAssets: FakeHook<
1393
- Pick<AsyncSeriesHook<[]>, "tap" | "tapAsync" | "tapPromise" | "name">
1400
+ Pick<AsyncSeriesHook<[]>, "name" | "tap" | "tapAsync" | "tapPromise">
1394
1401
  >;
1395
1402
  optimizeChunkAssets: FakeHook<
1396
1403
  Pick<
1397
1404
  AsyncSeriesHook<[Set<Chunk>]>,
1398
- "tap" | "tapAsync" | "tapPromise" | "name"
1405
+ "name" | "tap" | "tapAsync" | "tapPromise"
1399
1406
  >
1400
1407
  >;
1401
1408
  afterOptimizeChunkAssets: FakeHook<
1402
1409
  Pick<
1403
1410
  AsyncSeriesHook<[Set<Chunk>]>,
1404
- "tap" | "tapAsync" | "tapPromise" | "name"
1411
+ "name" | "tap" | "tapAsync" | "tapPromise"
1405
1412
  >
1406
1413
  >;
1407
1414
  optimizeAssets: AsyncSeriesHook<
@@ -1850,7 +1857,7 @@ declare interface CompilationParams {
1850
1857
  contextModuleFactory: ContextModuleFactory;
1851
1858
  }
1852
1859
  declare class Compiler {
1853
- constructor(context: string);
1860
+ constructor(context: string, options?: WebpackOptionsNormalized);
1854
1861
  hooks: Readonly<{
1855
1862
  initialize: SyncHook<[]>;
1856
1863
  shouldEmit: SyncBailHook<[Compilation], boolean>;
@@ -2448,7 +2455,7 @@ declare abstract class ContextModuleFactory extends ModuleFactory {
2448
2455
  alternatives: FakeHook<
2449
2456
  Pick<
2450
2457
  AsyncSeriesWaterfallHook<[any[]]>,
2451
- "tap" | "tapAsync" | "tapPromise" | "name"
2458
+ "name" | "tap" | "tapAsync" | "tapPromise"
2452
2459
  >
2453
2460
  >;
2454
2461
  alternativeRequests: AsyncSeriesWaterfallHook<
@@ -3297,14 +3304,14 @@ type Experiments = ExperimentsCommon & ExperimentsExtra;
3297
3304
  */
3298
3305
  declare interface ExperimentsCommon {
3299
3306
  /**
3300
- * Allow module type 'asset' to generate assets.
3307
+ * Support WebAssembly as asynchronous EcmaScript Module.
3301
3308
  */
3302
- asset?: boolean;
3309
+ asyncWebAssembly?: boolean;
3303
3310
 
3304
3311
  /**
3305
- * Support WebAssembly as asynchronous EcmaScript Module.
3312
+ * Enable backward-compat layer with deprecation warnings for many webpack 4 APIs.
3306
3313
  */
3307
- asyncWebAssembly?: boolean;
3314
+ backCompat?: boolean;
3308
3315
 
3309
3316
  /**
3310
3317
  * Enable additional in memory caching of modules that are unchanged and reference only unchanged modules.
@@ -3317,7 +3324,7 @@ declare interface ExperimentsCommon {
3317
3324
  futureDefaults?: boolean;
3318
3325
 
3319
3326
  /**
3320
- * Enable module and chunk layers.
3327
+ * Enable module layers.
3321
3328
  */
3322
3329
  layers?: boolean;
3323
3330
 
@@ -3852,6 +3859,7 @@ declare interface FactorizeModuleOptions {
3852
3859
  type FakeHook<T> = T & FakeHookMarker;
3853
3860
  declare interface FakeHookMarker {}
3854
3861
  declare interface FallbackCacheGroup {
3862
+ chunksFilter: (chunk: Chunk) => boolean;
3855
3863
  minSize: SplitChunksSizes;
3856
3864
  maxAsyncSize: SplitChunksSizes;
3857
3865
  maxInitialSize: SplitChunksSizes;
@@ -5282,6 +5290,11 @@ declare interface JavascriptParserOptions {
5282
5290
  */
5283
5291
  commonjsMagicComments?: boolean;
5284
5292
 
5293
+ /**
5294
+ * Specifies the behavior of invalid export names in "import ... from ..." and "export ... from ...".
5295
+ */
5296
+ exportsPresence?: false | "error" | "warn" | "auto";
5297
+
5285
5298
  /**
5286
5299
  * Enable warnings for full dynamic dependencies.
5287
5300
  */
@@ -5312,11 +5325,21 @@ declare interface JavascriptParserOptions {
5312
5325
  */
5313
5326
  import?: boolean;
5314
5327
 
5328
+ /**
5329
+ * Specifies the behavior of invalid export names in "import ... from ...".
5330
+ */
5331
+ importExportsPresence?: false | "error" | "warn" | "auto";
5332
+
5315
5333
  /**
5316
5334
  * Include polyfills or mocks for various node stuff.
5317
5335
  */
5318
5336
  node?: false | NodeOptions;
5319
5337
 
5338
+ /**
5339
+ * Specifies the behavior of invalid export names in "export ... from ...". This might be useful to disable during the migration from "export ... from ..." to "export type ... from ..." when reexporting types in TypeScript.
5340
+ */
5341
+ reexportExportsPresence?: false | "error" | "warn" | "auto";
5342
+
5320
5343
  /**
5321
5344
  * Enable/disable parsing of require.context syntax.
5322
5345
  */
@@ -5338,7 +5361,7 @@ declare interface JavascriptParserOptions {
5338
5361
  requireJs?: boolean;
5339
5362
 
5340
5363
  /**
5341
- * Emit errors instead of warnings when imported names don't exist in imported module.
5364
+ * Deprecated in favor of "exportsPresence". Emit errors instead of warnings when imported names don't exist in imported module.
5342
5365
  */
5343
5366
  strictExportPresence?: boolean;
5344
5367
 
@@ -5794,25 +5817,45 @@ declare interface KnownStatsProfile {
5794
5817
  dependencies: number;
5795
5818
  }
5796
5819
 
5820
+ /**
5821
+ * Options for the default backend.
5822
+ */
5823
+ declare interface LazyCompilationDefaultBackendOptions {
5824
+ /**
5825
+ * A custom client.
5826
+ */
5827
+ client?: string;
5828
+
5829
+ /**
5830
+ * Specifies where to listen to from the server.
5831
+ */
5832
+ listen?: number | ListenOptions | ((server: typeof Server) => void);
5833
+
5834
+ /**
5835
+ * Specifies the protocol the client should use to connect to the server.
5836
+ */
5837
+ protocol?: "http" | "https";
5838
+
5839
+ /**
5840
+ * Specifies how to create the server handling the EventSource requests.
5841
+ */
5842
+ server?: ServerOptionsImport | ServerOptionsHttps | (() => typeof Server);
5843
+ }
5844
+
5797
5845
  /**
5798
5846
  * Options for compiling entrypoints and import()s only when they are accessed.
5799
5847
  */
5800
5848
  declare interface LazyCompilationOptions {
5801
5849
  /**
5802
- * A custom backend.
5850
+ * Specifies the backend that should be used for handling client keep alive.
5803
5851
  */
5804
5852
  backend?:
5805
5853
  | ((
5806
5854
  compiler: Compiler,
5807
- client: string,
5808
- callback: (err?: Error, api?: any) => void
5855
+ callback: (err?: Error, api?: BackendApi) => void
5809
5856
  ) => void)
5810
- | ((compiler: Compiler, client: string) => Promise<any>);
5811
-
5812
- /**
5813
- * A custom client.
5814
- */
5815
- client?: string;
5857
+ | ((compiler: Compiler) => Promise<BackendApi>)
5858
+ | LazyCompilationDefaultBackendOptions;
5816
5859
 
5817
5860
  /**
5818
5861
  * Enable/disable lazy compilation for entries.
@@ -7485,6 +7528,7 @@ declare interface NormalModuleLoaderContext<OptionsType> {
7485
7528
  utils: {
7486
7529
  absolutify: (context: string, request: string) => string;
7487
7530
  contextify: (context: string, request: string) => string;
7531
+ createHash: (algorithm?: string) => Hash;
7488
7532
  };
7489
7533
  rootContext: string;
7490
7534
  fs: InputFileSystem;
@@ -7903,6 +7947,10 @@ declare interface OptimizationSplitChunksOptions {
7903
7947
  * Sets the name delimiter for created chunks.
7904
7948
  */
7905
7949
  automaticNameDelimiter?: string;
7950
+ /**
7951
+ * Select chunks for determining shared modules (defaults to "async", "initial" and "all" requires adding these chunks to the HTML).
7952
+ */
7953
+ chunks?: "all" | "initial" | "async" | ((chunk: Chunk) => boolean);
7906
7954
  /**
7907
7955
  * Maximal size hint for the on-demand chunks.
7908
7956
  */
@@ -10369,6 +10417,9 @@ declare abstract class Serializer {
10369
10417
  serialize(obj?: any, context?: any): any;
10370
10418
  deserialize(value?: any, context?: any): any;
10371
10419
  }
10420
+ type ServerOptionsHttps = SecureContextOptions &
10421
+ TlsOptions &
10422
+ ServerOptionsImport;
10372
10423
  declare class SharePlugin {
10373
10424
  constructor(options: SharePluginOptions);
10374
10425