@rspack/core 1.1.8 → 1.2.0-beta.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.
Files changed (86) hide show
  1. package/compiled/@swc/types/index.d.ts +20 -5
  2. package/compiled/@swc/types/license +1 -1
  3. package/compiled/@swc/types/package.json +1 -1
  4. package/dist/Chunk.d.ts +21 -28
  5. package/dist/ChunkGraph.d.ts +8 -4
  6. package/dist/ChunkGroup.d.ts +13 -19
  7. package/dist/Compilation.d.ts +5 -9
  8. package/dist/Compiler.d.ts +1 -0
  9. package/dist/Entrypoint.d.ts +4 -3
  10. package/dist/ExportsInfo.d.ts +20 -0
  11. package/dist/FileSystem.d.ts +17 -17
  12. package/dist/Module.d.ts +6 -8
  13. package/dist/ModuleGraph.d.ts +6 -0
  14. package/dist/ModuleGraphConnection.d.ts +11 -0
  15. package/dist/builtin-plugin/APIPlugin.d.ts +1 -1
  16. package/dist/builtin-plugin/ArrayPushCallbackChunkFormatPlugin.d.ts +1 -1
  17. package/dist/builtin-plugin/AssetModulesPlugin.d.ts +1 -1
  18. package/dist/builtin-plugin/AsyncWebAssemblyModulesPlugin.d.ts +1 -1
  19. package/dist/builtin-plugin/BannerPlugin.d.ts +1 -1
  20. package/dist/builtin-plugin/BundlerInfoRspackPlugin.d.ts +1 -1
  21. package/dist/builtin-plugin/ChunkPrefetchPreloadPlugin.d.ts +1 -1
  22. package/dist/builtin-plugin/CommonJsChunkFormatPlugin.d.ts +1 -1
  23. package/dist/builtin-plugin/ContextReplacementPlugin.d.ts +1 -1
  24. package/dist/builtin-plugin/CopyRspackPlugin.d.ts +1 -1
  25. package/dist/builtin-plugin/CssModulesPlugin.d.ts +1 -1
  26. package/dist/builtin-plugin/DataUriPlugin.d.ts +1 -1
  27. package/dist/builtin-plugin/DefinePlugin.d.ts +1 -1
  28. package/dist/builtin-plugin/DeterministicChunkIdsPlugin.d.ts +8 -10
  29. package/dist/builtin-plugin/DllEntryPlugin.d.ts +1 -1
  30. package/dist/builtin-plugin/DllReferenceAgencyPlugin.d.ts +1 -1
  31. package/dist/builtin-plugin/ElectronTargetPlugin.d.ts +1 -1
  32. package/dist/builtin-plugin/EnableChunkLoadingPlugin.d.ts +1 -1
  33. package/dist/builtin-plugin/EnableWasmLoadingPlugin.d.ts +1 -1
  34. package/dist/builtin-plugin/EnsureChunkConditionsPlugin.d.ts +1 -1
  35. package/dist/builtin-plugin/EntryPlugin.d.ts +11 -3
  36. package/dist/builtin-plugin/EvalDevToolModulePlugin.d.ts +1 -1
  37. package/dist/builtin-plugin/EvalSourceMapDevToolPlugin.d.ts +1 -1
  38. package/dist/builtin-plugin/FetchCompileAsyncWasmPlugin.d.ts +1 -1
  39. package/dist/builtin-plugin/FileUriPlugin.d.ts +1 -1
  40. package/dist/builtin-plugin/FlagAllModulesAsUsedPlugin.d.ts +1 -1
  41. package/dist/builtin-plugin/FlagDependencyExportsPlugin.d.ts +1 -1
  42. package/dist/builtin-plugin/HtmlRspackPlugin.d.ts +1 -1
  43. package/dist/builtin-plugin/HttpExternalsRspackPlugin.d.ts +1 -1
  44. package/dist/builtin-plugin/IgnorePlugin.d.ts +1 -1
  45. package/dist/builtin-plugin/InferAsyncModulesPlugin.d.ts +1 -1
  46. package/dist/builtin-plugin/JsLoaderRspackPlugin.d.ts +1 -1
  47. package/dist/builtin-plugin/JsonModulesPlugin.d.ts +1 -1
  48. package/dist/builtin-plugin/LibManifestPlugin.d.ts +1 -1
  49. package/dist/builtin-plugin/LightningCssMinimizerRspackPlugin.d.ts +1 -1
  50. package/dist/builtin-plugin/LimitChunkCountPlugin.d.ts +1 -1
  51. package/dist/builtin-plugin/MergeDuplicateChunksPlugin.d.ts +1 -1
  52. package/dist/builtin-plugin/ModuleChunkFormatPlugin.d.ts +1 -1
  53. package/dist/builtin-plugin/NamedChunkIdsPlugin.d.ts +1 -1
  54. package/dist/builtin-plugin/NamedModuleIdsPlugin.d.ts +1 -1
  55. package/dist/builtin-plugin/NaturalChunkIdsPlugin.d.ts +8 -10
  56. package/dist/builtin-plugin/NoEmitOnErrorsPlugin.d.ts +1 -1
  57. package/dist/builtin-plugin/NodeTargetPlugin.d.ts +1 -1
  58. package/dist/builtin-plugin/OccurrenceChunkIdsPlugin.d.ts +10 -0
  59. package/dist/builtin-plugin/ProgressPlugin.d.ts +1 -1
  60. package/dist/builtin-plugin/ProvidePlugin.d.ts +1 -1
  61. package/dist/builtin-plugin/RealContentHashPlugin.d.ts +1 -1
  62. package/dist/builtin-plugin/RemoveDuplicateModulesPlugin.d.ts +1 -1
  63. package/dist/builtin-plugin/RemoveEmptyChunksPlugin.d.ts +1 -1
  64. package/dist/builtin-plugin/RuntimeChunkPlugin.d.ts +1 -1
  65. package/dist/builtin-plugin/RuntimePlugin.d.ts +1 -1
  66. package/dist/builtin-plugin/SideEffectsFlagPlugin.d.ts +1 -1
  67. package/dist/builtin-plugin/SizeLimitsPlugin.d.ts +1 -1
  68. package/dist/builtin-plugin/SourceMapDevToolPlugin.d.ts +1 -1
  69. package/dist/builtin-plugin/SwcJsMinimizerPlugin.d.ts +1 -1
  70. package/dist/builtin-plugin/WarnCaseSensitiveModulesPlugin.d.ts +1 -1
  71. package/dist/builtin-plugin/base.d.ts +1 -1
  72. package/dist/builtin-plugin/css-extract/index.d.ts +1 -0
  73. package/dist/builtin-plugin/index.d.ts +1 -0
  74. package/dist/builtin-plugin/lazy-compilation/lazyCompilation.d.ts +1 -1
  75. package/dist/config/adapter.d.ts +2 -4
  76. package/dist/config/adapterRuleUse.d.ts +32 -8
  77. package/dist/config/normalization.d.ts +18 -2
  78. package/dist/config/types.d.ts +33 -11
  79. package/dist/config/zod.d.ts +1279 -1253
  80. package/dist/container/ContainerPlugin.d.ts +1 -1
  81. package/dist/container/ModuleFederationRuntimePlugin.d.ts +1 -1
  82. package/dist/exports.d.ts +1 -0
  83. package/dist/index.js +1376 -1379
  84. package/dist/util/hash/wasm-hash.d.ts +1 -1
  85. package/dist/util/identifier.d.ts +0 -36
  86. package/package.json +8 -7
@@ -1,3 +1,4 @@
1
+ import { Assumptions } from "./assumptions";
1
2
  export interface Plugin {
2
3
  (module: Program): Program;
3
4
  }
@@ -82,7 +83,7 @@ export interface JsFormatOptions {
82
83
  * Currently noop.
83
84
  * @alias inline_script
84
85
  */
85
- inlineScript?: number;
86
+ inlineScript?: boolean;
86
87
  /**
87
88
  * Currently noop.
88
89
  * @alias keep_numbers
@@ -465,6 +466,7 @@ export interface EnvConfig {
465
466
  forceAllTransforms?: boolean;
466
467
  }
467
468
  export interface JscConfig {
469
+ assumptions?: Assumptions;
468
470
  loose?: boolean;
469
471
  /**
470
472
  * Defaults to EsParserConfig
@@ -490,6 +492,8 @@ export interface JscConfig {
490
492
  optimizeHygiene?: boolean;
491
493
  /**
492
494
  * Preserve `with` in imports and exports.
495
+ *
496
+ * @deprecated Use `keepImportAssertions` instead.
493
497
  */
494
498
  keepImportAttributes?: boolean;
495
499
  /**
@@ -511,6 +515,12 @@ export interface JscConfig {
511
515
  * Second parameter of tuple is JSON based configuration for the plugin.
512
516
  */
513
517
  plugins?: Array<[string, Record<string, any>]>;
518
+ /**
519
+ * Run Wasm plugins before stripping TypeScript or decorators.
520
+ *
521
+ * See https://github.com/swc-project/swc/issues/9132 for more details.
522
+ */
523
+ runPluginFirst?: boolean;
514
524
  /**
515
525
  * Disable builtin transforms. If enabled, only Wasm plugins are used.
516
526
  */
@@ -519,6 +529,14 @@ export interface JscConfig {
519
529
  * Emit isolated dts files for each module.
520
530
  */
521
531
  emitIsolatedDts?: boolean;
532
+ /**
533
+ * Disable all lint rules.
534
+ */
535
+ disableAllLints?: boolean;
536
+ /**
537
+ * Keep import assertions.
538
+ */
539
+ keepImportAssertions?: boolean;
522
540
  };
523
541
  baseUrl?: string;
524
542
  paths?: {
@@ -527,7 +545,7 @@ export interface JscConfig {
527
545
  minify?: JsMinifyOptions;
528
546
  preserveAllComments?: boolean;
529
547
  }
530
- export type JscTarget = "es3" | "es5" | "es2015" | "es2016" | "es2017" | "es2018" | "es2019" | "es2020" | "es2021" | "es2022" | "esnext";
548
+ export type JscTarget = "es3" | "es5" | "es2015" | "es2016" | "es2017" | "es2018" | "es2019" | "es2020" | "es2021" | "es2022" | "es2023" | "es2024" | "esnext";
531
549
  export type ParserConfig = TsParserConfig | EsParserConfig;
532
550
  export interface TsParserConfig {
533
551
  syntax: "typescript";
@@ -1676,10 +1694,7 @@ export interface TsPropertySignature extends Node, HasSpan {
1676
1694
  key: Expression;
1677
1695
  computed: boolean;
1678
1696
  optional: boolean;
1679
- init?: Expression;
1680
- params: TsFnParameter[];
1681
1697
  typeAnnotation?: TsTypeAnnotation;
1682
- typeParams?: TsTypeParameterDeclaration;
1683
1698
  }
1684
1699
  export interface TsGetterSignature extends Node, HasSpan {
1685
1700
  type: "TsGetterSignature";
@@ -186,7 +186,7 @@ APPENDIX: How to apply the Apache License to your work.
186
186
  same "printed page" as the copyright notice for easier
187
187
  identification within third-party archives.
188
188
 
189
- Copyright [yyyy] [name of copyright owner]
189
+ Copyright 2024 SWC contributors.
190
190
 
191
191
  Licensed under the Apache License, Version 2.0 (the "License");
192
192
  you may not use this file except in compliance with the License.
@@ -1 +1 @@
1
- {"name":"@swc/types","author":"강동윤 <kdy1997.dev@gmail.com>","version":"0.1.12","license":"Apache-2.0","types":"index.d.ts","type":"commonjs"}
1
+ {"name":"@swc/types","author":"강동윤 <kdy1997.dev@gmail.com>","version":"0.1.17","license":"Apache-2.0","types":"index.d.ts","type":"commonjs"}
package/dist/Chunk.d.ts CHANGED
@@ -1,40 +1,33 @@
1
- import { type JsChunk, type JsCompilation } from "@rspack/binding";
2
- import { Compilation } from ".";
1
+ import type { JsChunk } from "@rspack/binding";
3
2
  import { ChunkGroup } from "./ChunkGroup";
4
3
  export declare class Chunk {
5
4
  #private;
6
- name?: Readonly<string>;
7
- id?: Readonly<string>;
8
- ids: ReadonlyArray<string>;
9
- idNameHints: ReadonlyArray<string>;
10
- filenameTemplate?: Readonly<string>;
11
- cssFilenameTemplate?: Readonly<string>;
12
- files: ReadonlySet<string>;
13
- runtime: ReadonlySet<string>;
14
- hash?: Readonly<string>;
15
- contentHash: Readonly<Record<string, string>>;
16
- renderedHash?: Readonly<string>;
17
- chunkReason?: Readonly<string>;
18
- auxiliaryFiles: ReadonlySet<string>;
19
- static __from_binding(chunk: JsChunk, compilation: Compilation): Chunk;
20
- static __from_binding(chunk: JsChunk, compilation: JsCompilation): Chunk;
21
- constructor(chunk: JsChunk, compilation: JsCompilation);
5
+ readonly name?: string;
6
+ readonly id?: string;
7
+ readonly ids: ReadonlyArray<string>;
8
+ readonly idNameHints: ReadonlyArray<string>;
9
+ readonly filenameTemplate?: string;
10
+ readonly cssFilenameTemplate?: string;
11
+ readonly files: ReadonlySet<string>;
12
+ readonly runtime: ReadonlySet<string>;
13
+ readonly hash?: string;
14
+ readonly contentHash: Readonly<Record<string, string>>;
15
+ readonly renderedHash?: string;
16
+ readonly chunkReason?: string;
17
+ readonly auxiliaryFiles: ReadonlySet<string>;
18
+ static __from_binding(binding: JsChunk): Chunk;
19
+ static __to_binding(chunk: Chunk): JsChunk;
20
+ constructor(binding: JsChunk);
22
21
  isOnlyInitial(): boolean;
23
22
  canBeInitial(): boolean;
24
23
  hasRuntime(): boolean;
25
- get groupsIterable(): Iterable<ChunkGroup>;
24
+ get groupsIterable(): ReadonlySet<ChunkGroup>;
26
25
  getChunkMaps(realHash: boolean): {
27
26
  hash: Record<string | number, string>;
28
27
  contentHash: Record<string | number, Record<string, string>>;
29
28
  name: Record<string | number, string>;
30
29
  };
31
- getAllAsyncChunks(): Iterable<Chunk>;
32
- getAllInitialChunks(): Iterable<Chunk>;
33
- getAllReferencedChunks(): Iterable<Chunk>;
34
- /**
35
- * Note: This is not a webpack public API, maybe removed in future.
36
- *
37
- * @internal
38
- */
39
- __internal__innerUkey(): number;
30
+ getAllAsyncChunks(): ReadonlySet<Chunk>;
31
+ getAllInitialChunks(): ReadonlySet<Chunk>;
32
+ getAllReferencedChunks(): ReadonlySet<Chunk>;
40
33
  }
@@ -1,12 +1,16 @@
1
+ import type { JsChunkGraph } from "@rspack/binding";
1
2
  import { Chunk } from "./Chunk";
2
- import type { Compilation } from "./Compilation";
3
3
  import { Module } from "./Module";
4
4
  export declare class ChunkGraph {
5
- private compilation;
6
- constructor(compilation: Compilation);
7
- getChunkModules(chunk: Chunk): Readonly<Module[]>;
5
+ #private;
6
+ static __from_binding(binding: JsChunkGraph): ChunkGraph;
7
+ private constructor();
8
+ getChunkModules(chunk: Chunk): ReadonlyArray<Module>;
8
9
  getChunkModulesIterable(chunk: Chunk): Iterable<Module>;
9
10
  getChunkEntryModulesIterable(chunk: Chunk): Iterable<Module>;
10
11
  getChunkEntryDependentChunksIterable(chunk: Chunk): Iterable<Chunk>;
11
12
  getChunkModulesIterableBySourceType(chunk: Chunk, sourceType: string): Iterable<Module>;
13
+ getModuleChunks(module: Module): Chunk[];
14
+ getModuleChunksIterable(module: Module): Iterable<Chunk>;
15
+ getModuleId(module: Module): string | null;
12
16
  }
@@ -1,26 +1,20 @@
1
- import { type JsChunkGroup, type JsChunkGroupOrigin, type JsCompilation } from "@rspack/binding";
1
+ import type { JsChunkGroup } from "@rspack/binding";
2
2
  import { Chunk } from "./Chunk";
3
+ import { Module } from "./Module";
3
4
  export declare class ChunkGroup {
4
5
  #private;
5
- static __from_binding(chunk: JsChunkGroup, compilation: JsCompilation): ChunkGroup;
6
- protected constructor(inner: JsChunkGroup, compilation: JsCompilation);
6
+ readonly chunks: ReadonlyArray<Chunk>;
7
+ readonly index?: number;
8
+ readonly name?: string;
9
+ readonly origins: ReadonlyArray<ChunkGroupOrigin>;
10
+ static __from_binding(binding: JsChunkGroup): ChunkGroup;
11
+ protected constructor(inner: JsChunkGroup);
7
12
  getFiles(): ReadonlyArray<string>;
8
13
  getParents(): ReadonlyArray<ChunkGroup>;
9
14
  isInitial(): boolean;
10
- get chunks(): ReadonlyArray<Chunk>;
11
- get index(): Readonly<number | undefined>;
12
- get name(): Readonly<string | undefined>;
13
- get origins(): ReadonlyArray<JsChunkGroupOrigin>;
14
- /**
15
- * Note: This is not a webpack public API, maybe removed in future.
16
- *
17
- * @internal
18
- */
19
- __internal__innerUkey(): number;
20
- /**
21
- * Note: This is not a webpack public API, maybe removed in future.
22
- *
23
- * @internal
24
- */
25
- __internal__innerCompilation(): JsCompilation;
26
15
  }
16
+ interface ChunkGroupOrigin {
17
+ module?: Module;
18
+ request?: string;
19
+ }
20
+ export {};
@@ -25,7 +25,9 @@ import type { ResolverFactory } from "./ResolverFactory";
25
25
  import { type RspackError } from "./RspackError";
26
26
  import { RuntimeModule } from "./RuntimeModule";
27
27
  import { Stats, type StatsAsset, type StatsError, type StatsModule } from "./Stats";
28
+ import type { EntryOptions, EntryPlugin } from "./builtin-plugin";
28
29
  import type { Filename, OutputNormalized, RspackOptionsNormalized, RspackPluginInstance, StatsOptions, StatsValue } from "./config";
30
+ import WebpackError from "./lib/WebpackError";
29
31
  import { Logger } from "./logging/Logger";
30
32
  import { StatsFactory } from "./stats/StatsFactory";
31
33
  import { StatsPrinter } from "./stats/StatsPrinter";
@@ -185,6 +187,7 @@ export declare class Compilation {
185
187
  runtimeModule: liteTapable.SyncHook<[JsRuntimeModule, Chunk], void>;
186
188
  seal: liteTapable.SyncHook<[], void>;
187
189
  afterSeal: liteTapable.AsyncSeriesHook<[], void>;
190
+ needAdditionalPass: liteTapable.SyncBailHook<[], boolean>;
188
191
  }>;
189
192
  name?: string;
190
193
  startTime?: number;
@@ -202,6 +205,7 @@ export declare class Compilation {
202
205
  fileSystemInfo: {
203
206
  createSnapshot(): null;
204
207
  };
208
+ needAdditionalPass: boolean;
205
209
  constructor(compiler: Compiler, inner: JsCompilation);
206
210
  get hash(): Readonly<string | null>;
207
211
  get fullHash(): Readonly<string | null>;
@@ -230,15 +234,6 @@ export declare class Compilation {
230
234
  */
231
235
  get namedChunks(): ReadonlyMap<string, Readonly<Chunk>>;
232
236
  get entries(): Map<string, EntryData>;
233
- /**
234
- * Note: This is not a webpack public API, maybe removed in future.
235
- *
236
- * @internal
237
- */
238
- __internal__getCustomModule(moduleIdentifier: string): {
239
- buildInfo: Record<string, unknown>;
240
- buildMeta: Record<string, unknown>;
241
- };
242
237
  getCache(name: string): import("./lib/CacheFacade").CacheFacade;
243
238
  createStatsOptions(statsValue: StatsValue | undefined, context?: CreateStatsOptionsContext): NormalizedStatsOptions;
244
239
  createStatsFactory(options: StatsOptions): StatsFactory;
@@ -323,6 +318,7 @@ export declare class Compilation {
323
318
  createChildCompiler(name: string, outputOptions: OutputNormalized, plugins: RspackPluginInstance[]): Compiler;
324
319
  rebuildModule(m: Module, f: (err: Error, m: Module) => void): void;
325
320
  addRuntimeModule(chunk: Chunk, runtimeModule: RuntimeModule): void;
321
+ addInclude(context: string, dependency: ReturnType<typeof EntryPlugin.createDependency>, options: EntryOptions, callback: (err?: null | WebpackError, module?: Module) => void): void;
326
322
  /**
327
323
  * Get the `Source` of a given asset filename.
328
324
  *
@@ -66,6 +66,7 @@ declare class Compiler {
66
66
  afterCompile: liteTapable.AsyncSeriesHook<[Compilation]>;
67
67
  finishMake: liteTapable.AsyncSeriesHook<[Compilation]>;
68
68
  entryOption: liteTapable.SyncBailHook<[string, EntryNormalized], any>;
69
+ additionalPass: liteTapable.AsyncSeriesHook<[]>;
69
70
  };
70
71
  webpack: typeof rspack;
71
72
  rspack: typeof rspack;
@@ -1,8 +1,9 @@
1
- import { type JsChunkGroup, type JsCompilation } from "@rspack/binding";
1
+ import type { JsChunkGroup } from "@rspack/binding";
2
2
  import { Chunk } from "./Chunk";
3
3
  import { ChunkGroup } from "./ChunkGroup";
4
4
  export declare class Entrypoint extends ChunkGroup {
5
- static __from_binding(chunk: JsChunkGroup, compilation: JsCompilation): Entrypoint;
6
- protected constructor(inner: JsChunkGroup, compilation: JsCompilation);
5
+ #private;
6
+ static __from_binding(binding: JsChunkGroup): Entrypoint;
7
+ protected constructor(binding: JsChunkGroup);
7
8
  getRuntimeChunk(): Readonly<Chunk | null>;
8
9
  }
@@ -0,0 +1,20 @@
1
+ import type { JsExportsInfo } from "@rspack/binding";
2
+ type RuntimeSpec = string | string[] | undefined;
3
+ /**
4
+ * Unused: 0
5
+ * OnlyPropertiesUsed: 1
6
+ * NoInfo: 2
7
+ * Unknown: 3
8
+ * Used: 4
9
+ */
10
+ type UsageStateType = 0 | 1 | 2 | 3 | 4;
11
+ export declare class ExportsInfo {
12
+ #private;
13
+ static __from_binding(binding: JsExportsInfo): ExportsInfo;
14
+ private constructor();
15
+ isUsed(runtime: RuntimeSpec): boolean;
16
+ isModuleUsed(runtime: RuntimeSpec): boolean;
17
+ setUsedInUnknownWay(runtime: RuntimeSpec): boolean;
18
+ getUsed(name: string | string[], runtime: RuntimeSpec): UsageStateType;
19
+ }
20
+ export {};
@@ -1,23 +1,23 @@
1
1
  import type { NodeFsStats, ThreadsafeNodeFS } from "@rspack/binding";
2
2
  import { type IStats, type IntermediateFileSystem, type OutputFileSystem } from "./util/fs";
3
3
  declare class ThreadsafeOutputNodeFS implements ThreadsafeNodeFS {
4
- writeFile: (name: string, content: Buffer) => Promise<void> | void;
5
- removeFile: (name: string) => Promise<void> | void;
6
- mkdir: (name: string) => Promise<void> | void;
7
- mkdirp: (name: string) => Promise<string | void> | string | void;
8
- removeDirAll: (name: string) => Promise<string | void> | string | void;
9
- readDir: (name: string) => Promise<string[] | void> | string[] | void;
10
- readFile: (name: string) => Promise<Buffer | string | void> | Buffer | string | void;
11
- stat: (name: string) => Promise<NodeFsStats | void> | NodeFsStats | void;
12
- lstat: (name: string) => Promise<NodeFsStats | void> | NodeFsStats | void;
13
- open: (name: string, flags: string) => Promise<number | void> | number | void;
14
- rename: (from: string, to: string) => Promise<void> | void;
15
- close: (fd: number) => Promise<void> | void;
16
- write: (fd: number, content: Buffer, position: number) => Promise<number | void> | number | void;
17
- writeAll: (fd: number, content: Buffer) => Promise<number | void> | number | void;
18
- read: (fd: number, length: number, position: number) => Promise<Buffer | void> | Buffer | void;
19
- readUntil: (fd: number, code: number, position: number) => Promise<Buffer | void> | Buffer | void;
20
- readToEnd: (fd: number, position: number) => Promise<Buffer | void> | Buffer | void;
4
+ writeFile: (name: string, content: Buffer) => Promise<void>;
5
+ removeFile: (name: string) => Promise<void>;
6
+ mkdir: (name: string) => Promise<void>;
7
+ mkdirp: (name: string) => Promise<string | void>;
8
+ removeDirAll: (name: string) => Promise<string | void>;
9
+ readDir: (name: string) => Promise<string[] | void>;
10
+ readFile: (name: string) => Promise<Buffer | string | void>;
11
+ stat: (name: string) => Promise<NodeFsStats | void>;
12
+ lstat: (name: string) => Promise<NodeFsStats | void>;
13
+ open: (name: string, flags: string) => Promise<number | void>;
14
+ rename: (from: string, to: string) => Promise<void>;
15
+ close: (fd: number) => Promise<void>;
16
+ write: (fd: number, content: Buffer, position: number) => Promise<number | void>;
17
+ writeAll: (fd: number, content: Buffer) => Promise<number | void>;
18
+ read: (fd: number, length: number, position: number) => Promise<Buffer | void>;
19
+ readUntil: (fd: number, code: number, position: number) => Promise<Buffer | void>;
20
+ readToEnd: (fd: number, position: number) => Promise<Buffer | void>;
21
21
  constructor(fs?: OutputFileSystem);
22
22
  static __to_binding(fs?: OutputFileSystem): ThreadsafeOutputNodeFS;
23
23
  static __to_binding_stat(stat: IStats): NodeFsStats;
package/dist/Module.d.ts CHANGED
@@ -1,7 +1,6 @@
1
1
  import type { JsCodegenerationResult, JsContextModuleFactoryAfterResolveData, JsContextModuleFactoryBeforeResolveData, JsCreateData, JsFactoryMeta } from "@rspack/binding";
2
- import { JsModule } from "@rspack/binding";
2
+ import type { JsModule } from "@rspack/binding";
3
3
  import type { Source } from "../compiled/webpack-sources";
4
- import type { Compilation } from "./Compilation";
5
4
  import { DependenciesBlock } from "./DependenciesBlock";
6
5
  import { Dependency } from "./Dependency";
7
6
  export type ResourceData = {
@@ -16,6 +15,7 @@ export type ResourceDataWithData = ResourceData & {
16
15
  export type CreateData = Partial<JsCreateData>;
17
16
  export type ContextInfo = {
18
17
  issuer: string;
18
+ issuerLayer?: string;
19
19
  };
20
20
  export type ResolveData = {
21
21
  contextInfo: ContextInfo;
@@ -63,22 +63,20 @@ export declare class Module {
63
63
  /**
64
64
  * Records the dynamically added fields for Module on the JavaScript side.
65
65
  * These fields are generally used within a plugin, so they do not need to be passed back to the Rust side.
66
- * @see {@link Compilation#customModules}
67
66
  */
68
- readonly buildInfo: Record<string, any>;
67
+ buildInfo: Record<string, any>;
69
68
  /**
70
69
  * Records the dynamically added fields for Module on the JavaScript side.
71
70
  * These fields are generally used within a plugin, so they do not need to be passed back to the Rust side.
72
- * @see {@link Compilation#customModules}
73
71
  */
74
- readonly buildMeta: Record<string, any>;
72
+ buildMeta: Record<string, any>;
75
73
  readonly modules: Module[] | undefined;
76
74
  readonly blocks: DependenciesBlock[];
77
75
  readonly dependencies: Dependency[];
78
76
  readonly useSourceMap: boolean;
79
- static __from_binding(binding: JsModule, compilation?: Compilation): Module;
77
+ static __from_binding(binding: JsModule): Module;
80
78
  static __to_binding(module: Module): JsModule;
81
- constructor(module: JsModule, compilation?: Compilation);
79
+ constructor(module: JsModule);
82
80
  originalSource(): Source | null;
83
81
  identifier(): string;
84
82
  nameForCondition(): string | null;
@@ -1,10 +1,16 @@
1
1
  import type { JsModuleGraph } from "@rspack/binding";
2
2
  import { Dependency } from "./Dependency";
3
+ import { ExportsInfo } from "./ExportsInfo";
3
4
  import { Module } from "./Module";
5
+ import { ModuleGraphConnection } from "./ModuleGraphConnection";
4
6
  export default class ModuleGraph {
5
7
  #private;
6
8
  static __from_binding(binding: JsModuleGraph): ModuleGraph;
7
9
  private constructor();
8
10
  getModule(dependency: Dependency): Module | null;
11
+ getResolvedModule(dependency: Dependency): Module | null;
9
12
  getIssuer(module: Module): Module | null;
13
+ getExportsInfo(module: Module): ExportsInfo;
14
+ getConnection(dependency: Dependency): ModuleGraphConnection | null;
15
+ getOutgoingConnections(module: Module): ModuleGraphConnection[];
10
16
  }
@@ -0,0 +1,11 @@
1
+ import type { JsModuleGraphConnection } from "@rspack/binding";
2
+ import { Dependency } from "./Dependency";
3
+ import { Module } from "./Module";
4
+ export declare class ModuleGraphConnection {
5
+ #private;
6
+ readonly module: Module | null;
7
+ readonly dependency: Dependency;
8
+ static __from_binding(binding: JsModuleGraphConnection): ModuleGraphConnection;
9
+ static __to_binding(data: ModuleGraphConnection): JsModuleGraphConnection;
10
+ private constructor();
11
+ }
@@ -3,7 +3,7 @@ export declare const APIPlugin: {
3
3
  new (): {
4
4
  name: BuiltinPluginName;
5
5
  _args: [];
6
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
6
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
7
7
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
8
8
  apply(compiler: import("..").Compiler): void;
9
9
  };
@@ -3,7 +3,7 @@ export declare const ArrayPushCallbackChunkFormatPlugin: {
3
3
  new (): {
4
4
  name: BuiltinPluginName;
5
5
  _args: [];
6
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
6
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
7
7
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
8
8
  apply(compiler: import("..").Compiler): void;
9
9
  };
@@ -3,7 +3,7 @@ export declare const AssetModulesPlugin: {
3
3
  new (): {
4
4
  name: BuiltinPluginName;
5
5
  _args: [];
6
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
6
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
7
7
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
8
8
  apply(compiler: import("..").Compiler): void;
9
9
  };
@@ -3,7 +3,7 @@ export declare const AsyncWebAssemblyModulesPlugin: {
3
3
  new (): {
4
4
  name: BuiltinPluginName;
5
5
  _args: [];
6
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
6
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
7
7
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
8
8
  apply(compiler: import("..").Compiler): void;
9
9
  };
@@ -33,7 +33,7 @@ export declare const BannerPlugin: {
33
33
  new (args: BannerPluginArgument): {
34
34
  name: BuiltinPluginName;
35
35
  _args: [args: BannerPluginArgument];
36
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
36
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
37
37
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
38
38
  apply(compiler: import("..").Compiler): void;
39
39
  };
@@ -8,7 +8,7 @@ export declare const BundlerInfoRspackPlugin: {
8
8
  new (options: BundleInfoOptions): {
9
9
  name: BuiltinPluginName;
10
10
  _args: [options: BundleInfoOptions];
11
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
11
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
12
12
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
13
13
  apply(compiler: import("..").Compiler): void;
14
14
  };
@@ -3,7 +3,7 @@ export declare const ChunkPrefetchPreloadPlugin: {
3
3
  new (): {
4
4
  name: BuiltinPluginName;
5
5
  _args: [];
6
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
6
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
7
7
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
8
8
  apply(compiler: import("..").Compiler): void;
9
9
  };
@@ -3,7 +3,7 @@ export declare const CommonJsChunkFormatPlugin: {
3
3
  new (): {
4
4
  name: BuiltinPluginName;
5
5
  _args: [];
6
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
6
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
7
7
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
8
8
  apply(compiler: import("..").Compiler): void;
9
9
  };
@@ -3,7 +3,7 @@ export declare const ContextReplacementPlugin: {
3
3
  new (resourceRegExp: RegExp, newContentResource?: any, newContentRecursive?: any, newContentRegExp?: any): {
4
4
  name: BuiltinPluginName;
5
5
  _args: [resourceRegExp: RegExp, newContentResource?: any, newContentRecursive?: any, newContentRegExp?: any];
6
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
6
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
7
7
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
8
8
  apply(compiler: import("..").Compiler): void;
9
9
  };
@@ -8,7 +8,7 @@ export declare const CopyRspackPlugin: {
8
8
  new (copy: CopyRspackPluginOptions): {
9
9
  name: BuiltinPluginName;
10
10
  _args: [copy: CopyRspackPluginOptions];
11
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
11
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
12
12
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
13
13
  apply(compiler: import("..").Compiler): void;
14
14
  };
@@ -3,7 +3,7 @@ export declare const CssModulesPlugin: {
3
3
  new (): {
4
4
  name: BuiltinPluginName;
5
5
  _args: [];
6
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
6
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
7
7
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
8
8
  apply(compiler: import("..").Compiler): void;
9
9
  };
@@ -3,7 +3,7 @@ export declare const DataUriPlugin: {
3
3
  new (): {
4
4
  name: BuiltinPluginName;
5
5
  _args: [];
6
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
6
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
7
7
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
8
8
  apply(compiler: import("..").Compiler): void;
9
9
  };
@@ -4,7 +4,7 @@ export declare const DefinePlugin: {
4
4
  new (define: DefinePluginOptions): {
5
5
  name: BuiltinPluginName;
6
6
  _args: [define: DefinePluginOptions];
7
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
7
+ affectedHooks: "done" | "make" | "environment" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | "additionalPass" | undefined;
8
8
  raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
9
9
  apply(compiler: import("..").Compiler): void;
10
10
  };
@@ -1,10 +1,8 @@
1
- import { BuiltinPluginName } from "@rspack/binding";
2
- export declare const DeterministicChunkIdsPlugin: {
3
- new (): {
4
- name: BuiltinPluginName;
5
- _args: [];
6
- affectedHooks: "done" | "make" | "compile" | "emit" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "compilation" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "failed" | "shutdown" | "watchRun" | "watchClose" | "environment" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
7
- raw(compiler: import("..").Compiler): import("@rspack/binding").BuiltinPlugin;
8
- apply(compiler: import("..").Compiler): void;
9
- };
10
- };
1
+ import { type BuiltinPlugin, BuiltinPluginName } from "@rspack/binding";
2
+ import type { Compiler } from "../Compiler";
3
+ import { RspackBuiltinPlugin } from "./base";
4
+ export declare class DeterministicChunkIdsPlugin extends RspackBuiltinPlugin {
5
+ name: BuiltinPluginName;
6
+ affectedHooks: "compilation";
7
+ raw(compiler: Compiler): BuiltinPlugin;
8
+ }