@rspack/binding 1.1.0-beta.0 → 1.1.1
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/binding.d.ts +163 -118
- package/package.json +11 -11
package/binding.d.ts
CHANGED
|
@@ -13,42 +13,20 @@ export type RawLazyCompilationTest = RegExp | ((m: JsModule) => boolean);
|
|
|
13
13
|
|
|
14
14
|
/* -- napi-rs generated below -- */
|
|
15
15
|
|
|
16
|
-
export class ExternalObject<T> {
|
|
16
|
+
export declare class ExternalObject<T> {
|
|
17
17
|
readonly '': {
|
|
18
18
|
readonly '': unique symbol
|
|
19
19
|
[K: symbol]: T
|
|
20
20
|
}
|
|
21
21
|
}
|
|
22
|
-
export class
|
|
23
|
-
get dependencies(): Array<JsDependency>
|
|
24
|
-
get blocks(): Array<DependenciesBlockDto>
|
|
25
|
-
}
|
|
26
|
-
export type DependenciesBlockDTO = DependenciesBlockDto
|
|
27
|
-
|
|
28
|
-
export class DependenciesDto {
|
|
29
|
-
get fileDependencies(): Array<string>
|
|
30
|
-
get addedFileDependencies(): Array<string>
|
|
31
|
-
get removedFileDependencies(): Array<string>
|
|
32
|
-
get contextDependencies(): Array<string>
|
|
33
|
-
get addedContextDependencies(): Array<string>
|
|
34
|
-
get removedContextDependencies(): Array<string>
|
|
35
|
-
get missingDependencies(): Array<string>
|
|
36
|
-
get addedMissingDependencies(): Array<string>
|
|
37
|
-
get removedMissingDependencies(): Array<string>
|
|
38
|
-
get buildDependencies(): Array<string>
|
|
39
|
-
get addedBuildDependencies(): Array<string>
|
|
40
|
-
get removedBuildDependencies(): Array<string>
|
|
41
|
-
}
|
|
42
|
-
export type DependenciesDTO = DependenciesDto
|
|
43
|
-
|
|
44
|
-
export class EntryDataDto {
|
|
22
|
+
export declare class EntryDataDto {
|
|
45
23
|
get dependencies(): Array<JsDependency>
|
|
46
24
|
get includeDependencies(): Array<JsDependency>
|
|
47
25
|
get options(): EntryOptionsDto
|
|
48
26
|
}
|
|
49
27
|
export type EntryDataDTO = EntryDataDto
|
|
50
28
|
|
|
51
|
-
export class EntryOptionsDto {
|
|
29
|
+
export declare class EntryOptionsDto {
|
|
52
30
|
get name(): string | undefined
|
|
53
31
|
set name(name: string | undefined)
|
|
54
32
|
get runtime(): false | string | undefined
|
|
@@ -68,13 +46,13 @@ export class EntryOptionsDto {
|
|
|
68
46
|
}
|
|
69
47
|
export type EntryOptionsDTO = EntryOptionsDto
|
|
70
48
|
|
|
71
|
-
export class JsCompilation {
|
|
49
|
+
export declare class JsCompilation {
|
|
72
50
|
updateAsset(filename: string, newSourceOrFunction: JsCompatSource | ((source: JsCompatSource) => JsCompatSource), assetInfoUpdateOrFunction?: JsAssetInfo | ((assetInfo: JsAssetInfo) => JsAssetInfo)): void
|
|
73
51
|
getAssets(): Readonly<JsAsset>[]
|
|
74
52
|
getAsset(name: string): JsAsset | null
|
|
75
53
|
getAssetSource(name: string): JsCompatSource | null
|
|
76
|
-
get modules(): Array<
|
|
77
|
-
get builtModules(): Array<
|
|
54
|
+
get modules(): Array<JsModule>
|
|
55
|
+
get builtModules(): Array<JsModule>
|
|
78
56
|
getOptimizationBailout(): Array<JsStatsOptimizationBailout>
|
|
79
57
|
getChunks(): Array<JsChunk>
|
|
80
58
|
getNamedChunkKeys(): Array<string>
|
|
@@ -92,7 +70,7 @@ export class JsCompilation {
|
|
|
92
70
|
get entrypoints(): Record<string, JsChunkGroup>
|
|
93
71
|
get chunkGroups(): Array<JsChunkGroup>
|
|
94
72
|
get hash(): string | null
|
|
95
|
-
dependencies():
|
|
73
|
+
dependencies(): JsDependencies
|
|
96
74
|
pushDiagnostic(diagnostic: JsRspackDiagnostic): void
|
|
97
75
|
spliceDiagnostic(start: number, end: number, replaceWith: Array<JsRspackDiagnostic>): void
|
|
98
76
|
pushNativeDiagnostic(diagnostic: ExternalObject<'Diagnostic'>): void
|
|
@@ -108,45 +86,70 @@ export class JsCompilation {
|
|
|
108
86
|
addContextDependencies(deps: Array<string>): void
|
|
109
87
|
addMissingDependencies(deps: Array<string>): void
|
|
110
88
|
addBuildDependencies(deps: Array<string>): void
|
|
111
|
-
|
|
112
|
-
|
|
89
|
+
/**
|
|
90
|
+
* This is a very unsafe function.
|
|
91
|
+
* Please don't use this at the moment.
|
|
92
|
+
* Using async and mutable reference to `Compilation` at the same time would likely to cause data races.
|
|
93
|
+
*/
|
|
94
|
+
rebuildModule(moduleIdentifiers: Array<string>, f: any): void
|
|
95
|
+
importModule(request: string, layer: string | undefined | null, publicPath: JsFilename | undefined | null, baseUri: string | undefined | null, originalModule: string | undefined | null, originalModuleContext: string | undefined | null, callback: any): void
|
|
113
96
|
get entries(): JsEntries
|
|
114
97
|
addRuntimeModule(chunkUkey: number, runtimeModule: JsAddingRuntimeModule): void
|
|
115
98
|
}
|
|
116
99
|
|
|
117
|
-
export class JsContextModuleFactoryAfterResolveData {
|
|
100
|
+
export declare class JsContextModuleFactoryAfterResolveData {
|
|
118
101
|
get resource(): string
|
|
119
102
|
set resource(resource: string)
|
|
120
103
|
get context(): string
|
|
121
104
|
set context(context: string)
|
|
122
105
|
get request(): string
|
|
123
106
|
set request(request: string)
|
|
124
|
-
get regExp():
|
|
125
|
-
set regExp(rawRegExp:
|
|
107
|
+
get regExp(): RegExp | undefined
|
|
108
|
+
set regExp(rawRegExp: RegExp | undefined)
|
|
126
109
|
get recursive(): boolean
|
|
127
110
|
set recursive(recursive: boolean)
|
|
128
111
|
get dependencies(): Array<JsDependencyMut>
|
|
129
112
|
}
|
|
130
113
|
|
|
131
|
-
export class JsContextModuleFactoryBeforeResolveData {
|
|
114
|
+
export declare class JsContextModuleFactoryBeforeResolveData {
|
|
132
115
|
get context(): string
|
|
133
116
|
set context(context: string)
|
|
134
117
|
get request(): string
|
|
135
118
|
set request(request: string)
|
|
136
|
-
get regExp():
|
|
137
|
-
set regExp(rawRegExp:
|
|
119
|
+
get regExp(): RegExp | undefined
|
|
120
|
+
set regExp(rawRegExp: RegExp | undefined)
|
|
138
121
|
get recursive(): boolean
|
|
139
122
|
set recursive(recursive: boolean)
|
|
140
123
|
}
|
|
141
124
|
|
|
142
|
-
export class
|
|
125
|
+
export declare class JsDependencies {
|
|
126
|
+
get fileDependencies(): Array<string>
|
|
127
|
+
get addedFileDependencies(): Array<string>
|
|
128
|
+
get removedFileDependencies(): Array<string>
|
|
129
|
+
get contextDependencies(): Array<string>
|
|
130
|
+
get addedContextDependencies(): Array<string>
|
|
131
|
+
get removedContextDependencies(): Array<string>
|
|
132
|
+
get missingDependencies(): Array<string>
|
|
133
|
+
get addedMissingDependencies(): Array<string>
|
|
134
|
+
get removedMissingDependencies(): Array<string>
|
|
135
|
+
get buildDependencies(): Array<string>
|
|
136
|
+
get addedBuildDependencies(): Array<string>
|
|
137
|
+
get removedBuildDependencies(): Array<string>
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
export declare class JsDependenciesBlock {
|
|
141
|
+
get dependencies(): Array<JsDependency>
|
|
142
|
+
get blocks(): Array<JsDependenciesBlock>
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
export declare class JsDependency {
|
|
143
146
|
get type(): string
|
|
144
147
|
get category(): string
|
|
145
148
|
get request(): string | undefined
|
|
146
149
|
get critical(): boolean
|
|
147
150
|
}
|
|
148
151
|
|
|
149
|
-
export class JsDependencyMut {
|
|
152
|
+
export declare class JsDependencyMut {
|
|
150
153
|
get type(): string
|
|
151
154
|
get category(): string
|
|
152
155
|
get request(): string | undefined
|
|
@@ -154,7 +157,7 @@ export class JsDependencyMut {
|
|
|
154
157
|
set critical(val: boolean)
|
|
155
158
|
}
|
|
156
159
|
|
|
157
|
-
export class JsEntries {
|
|
160
|
+
export declare class JsEntries {
|
|
158
161
|
clear(): void
|
|
159
162
|
get size(): number
|
|
160
163
|
has(key: string): boolean
|
|
@@ -165,24 +168,7 @@ export class JsEntries {
|
|
|
165
168
|
values(): Array<EntryDataDto>
|
|
166
169
|
}
|
|
167
170
|
|
|
168
|
-
export class
|
|
169
|
-
resolveSync(path: string, request: string): string | false
|
|
170
|
-
withOptions(raw?: RawResolveOptionsWithDependencyType | undefined | null): this
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
export class JsResolverFactory {
|
|
174
|
-
constructor()
|
|
175
|
-
get(type: string, options?: RawResolveOptionsWithDependencyType): JsResolver
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
export class JsStats {
|
|
179
|
-
toJson(jsOptions: JsStatsOptions): JsStatsCompilation
|
|
180
|
-
hasWarnings(): boolean
|
|
181
|
-
hasErrors(): boolean
|
|
182
|
-
getLogging(acceptedTypes: number): Array<JsStatsLogging>
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
export class ModuleDto {
|
|
171
|
+
export declare class JsModule {
|
|
186
172
|
get context(): string | undefined
|
|
187
173
|
get originalSource(): JsCompatSource | undefined
|
|
188
174
|
get resource(): string | undefined
|
|
@@ -190,17 +176,36 @@ export class ModuleDto {
|
|
|
190
176
|
get nameForCondition(): string | undefined
|
|
191
177
|
get request(): string | undefined
|
|
192
178
|
get userRequest(): string | undefined
|
|
179
|
+
set userRequest(val: string)
|
|
193
180
|
get rawRequest(): string | undefined
|
|
194
181
|
get factoryMeta(): JsFactoryMeta | undefined
|
|
195
182
|
get type(): string
|
|
196
183
|
get layer(): string | undefined
|
|
197
|
-
get blocks(): Array<
|
|
184
|
+
get blocks(): Array<JsDependenciesBlock>
|
|
185
|
+
get dependencies(): Array<JsDependency>
|
|
198
186
|
size(ty?: string | undefined | null): number
|
|
199
|
-
get modules():
|
|
187
|
+
get modules(): JsModule[] | undefined
|
|
188
|
+
get useSourceMap(): boolean
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
export declare class JsResolver {
|
|
192
|
+
resolveSync(path: string, request: string): string | false
|
|
193
|
+
withOptions(raw?: RawResolveOptionsWithDependencyType | undefined | null): JsResolver
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
export declare class JsResolverFactory {
|
|
197
|
+
constructor()
|
|
198
|
+
get(type: string, options?: RawResolveOptionsWithDependencyType): JsResolver
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
export declare class JsStats {
|
|
202
|
+
toJson(jsOptions: JsStatsOptions): JsStatsCompilation
|
|
203
|
+
hasWarnings(): boolean
|
|
204
|
+
hasErrors(): boolean
|
|
205
|
+
getLogging(acceptedTypes: number): Array<JsStatsLogging>
|
|
200
206
|
}
|
|
201
|
-
export type ModuleDTO = ModuleDto
|
|
202
207
|
|
|
203
|
-
export class Rspack {
|
|
208
|
+
export declare class Rspack {
|
|
204
209
|
constructor(options: RawOptions, builtinPlugins: Array<BuiltinPlugin>, registerJsTaps: RegisterJsTaps, outputFilesystem: ThreadsafeNodeFS, resolverFactoryReference: JsResolverFactory)
|
|
205
210
|
setNonSkippableRegisters(kinds: Array<RegisterJsTapKind>): void
|
|
206
211
|
/** Build with the given option passed to the constructor */
|
|
@@ -209,29 +214,29 @@ export class Rspack {
|
|
|
209
214
|
rebuild(changed_files: string[], removed_files: string[], callback: (err: null | Error) => void): void
|
|
210
215
|
}
|
|
211
216
|
|
|
212
|
-
export function __chunk_graph_inner_get_chunk_entry_dependent_chunks_iterable(jsChunkUkey: number,
|
|
217
|
+
export declare function __chunk_graph_inner_get_chunk_entry_dependent_chunks_iterable(jsChunkUkey: number, jsCompilation: JsCompilation): Array<JsChunk>
|
|
213
218
|
|
|
214
|
-
export function __chunk_graph_inner_get_chunk_entry_modules(jsChunkUkey: number,
|
|
219
|
+
export declare function __chunk_graph_inner_get_chunk_entry_modules(jsChunkUkey: number, jsCompilation: JsCompilation): JsModule[]
|
|
215
220
|
|
|
216
|
-
export function __chunk_graph_inner_get_chunk_modules(jsChunkUkey: number,
|
|
221
|
+
export declare function __chunk_graph_inner_get_chunk_modules(jsChunkUkey: number, jsCompilation: JsCompilation): JsModule[]
|
|
217
222
|
|
|
218
|
-
export function __chunk_graph_inner_get_chunk_modules_iterable_by_source_type(jsChunkUkey: number, sourceType: string,
|
|
223
|
+
export declare function __chunk_graph_inner_get_chunk_modules_iterable_by_source_type(jsChunkUkey: number, sourceType: string, jsCompilation: JsCompilation): JsModule[]
|
|
219
224
|
|
|
220
|
-
export function __chunk_group_inner_get_chunk_group(ukey: number,
|
|
225
|
+
export declare function __chunk_group_inner_get_chunk_group(ukey: number, jsCompilation: JsCompilation): JsChunkGroup
|
|
221
226
|
|
|
222
|
-
export function __chunk_inner_can_be_initial(jsChunkUkey: number,
|
|
227
|
+
export declare function __chunk_inner_can_be_initial(jsChunkUkey: number, jsCompilation: JsCompilation): boolean
|
|
223
228
|
|
|
224
|
-
export function __chunk_inner_get_all_async_chunks(jsChunkUkey: number,
|
|
229
|
+
export declare function __chunk_inner_get_all_async_chunks(jsChunkUkey: number, jsCompilation: JsCompilation): Array<JsChunk>
|
|
225
230
|
|
|
226
|
-
export function __chunk_inner_get_all_initial_chunks(jsChunkUkey: number,
|
|
231
|
+
export declare function __chunk_inner_get_all_initial_chunks(jsChunkUkey: number, jsCompilation: JsCompilation): Array<JsChunk>
|
|
227
232
|
|
|
228
|
-
export function __chunk_inner_get_all_referenced_chunks(jsChunkUkey: number,
|
|
233
|
+
export declare function __chunk_inner_get_all_referenced_chunks(jsChunkUkey: number, jsCompilation: JsCompilation): Array<JsChunk>
|
|
229
234
|
|
|
230
|
-
export function __chunk_inner_has_runtime(jsChunkUkey: number,
|
|
235
|
+
export declare function __chunk_inner_has_runtime(jsChunkUkey: number, jsCompilation: JsCompilation): boolean
|
|
231
236
|
|
|
232
|
-
export function __chunk_inner_is_only_initial(jsChunkUkey: number,
|
|
237
|
+
export declare function __chunk_inner_is_only_initial(jsChunkUkey: number, jsCompilation: JsCompilation): boolean
|
|
233
238
|
|
|
234
|
-
export function __entrypoint_inner_get_runtime_chunk(ukey: number,
|
|
239
|
+
export declare function __entrypoint_inner_get_runtime_chunk(ukey: number, jsCompilation: JsCompilation): JsChunk
|
|
235
240
|
|
|
236
241
|
export interface BuiltinPlugin {
|
|
237
242
|
name: BuiltinPluginName
|
|
@@ -239,7 +244,7 @@ export interface BuiltinPlugin {
|
|
|
239
244
|
canInherentFromParent?: boolean
|
|
240
245
|
}
|
|
241
246
|
|
|
242
|
-
export enum BuiltinPluginName {
|
|
247
|
+
export declare enum BuiltinPluginName {
|
|
243
248
|
DefinePlugin = 'DefinePlugin',
|
|
244
249
|
ProvidePlugin = 'ProvidePlugin',
|
|
245
250
|
BannerPlugin = 'BannerPlugin',
|
|
@@ -303,6 +308,10 @@ export enum BuiltinPluginName {
|
|
|
303
308
|
SizeLimitsPlugin = 'SizeLimitsPlugin',
|
|
304
309
|
NoEmitOnErrorsPlugin = 'NoEmitOnErrorsPlugin',
|
|
305
310
|
ContextReplacementPlugin = 'ContextReplacementPlugin',
|
|
311
|
+
DllEntryPlugin = 'DllEntryPlugin',
|
|
312
|
+
DllReferenceAgencyPlugin = 'DllReferenceAgencyPlugin',
|
|
313
|
+
LibManifestPlugin = 'LibManifestPlugin',
|
|
314
|
+
FlagAllModulesAsUsedPlugin = 'FlagAllModulesAsUsedPlugin',
|
|
306
315
|
HttpExternalsRspackPlugin = 'HttpExternalsRspackPlugin',
|
|
307
316
|
CopyRspackPlugin = 'CopyRspackPlugin',
|
|
308
317
|
HtmlRspackPlugin = 'HtmlRspackPlugin',
|
|
@@ -314,18 +323,19 @@ export enum BuiltinPluginName {
|
|
|
314
323
|
LazyCompilationPlugin = 'LazyCompilationPlugin'
|
|
315
324
|
}
|
|
316
325
|
|
|
317
|
-
export function cleanupGlobalTrace(): void
|
|
326
|
+
export declare function cleanupGlobalTrace(): void
|
|
318
327
|
|
|
319
328
|
export interface ContextInfo {
|
|
320
329
|
issuer: string
|
|
321
330
|
}
|
|
322
331
|
|
|
323
|
-
export function formatDiagnostic(diagnostic: JsDiagnostic): ExternalObject<'Diagnostic'>
|
|
332
|
+
export declare function formatDiagnostic(diagnostic: JsDiagnostic): ExternalObject<'Diagnostic'>
|
|
324
333
|
|
|
325
334
|
export interface JsAddingRuntimeModule {
|
|
326
335
|
name: string
|
|
327
336
|
generator: () => String
|
|
328
|
-
|
|
337
|
+
dependentHash: boolean
|
|
338
|
+
fullHash: boolean
|
|
329
339
|
isolate: boolean
|
|
330
340
|
stage: number
|
|
331
341
|
}
|
|
@@ -445,13 +455,29 @@ export interface JsBeforeResolveArgs {
|
|
|
445
455
|
issuer: string
|
|
446
456
|
}
|
|
447
457
|
|
|
458
|
+
export interface JsBuildMeta {
|
|
459
|
+
strictEsmModule: boolean
|
|
460
|
+
hasTopLevelAwait: boolean
|
|
461
|
+
esm: boolean
|
|
462
|
+
exportsType: 'unset' | 'default' | 'namespace' | 'flagged' | 'dynamic'
|
|
463
|
+
defaultObject: 'false' | 'redirect' | JsBuildMetaDefaultObjectRedirectWarn
|
|
464
|
+
moduleArgument: 'module' | 'webpackModule'
|
|
465
|
+
exportsArgument: 'exports' | 'webpackExports'
|
|
466
|
+
sideEffectFree?: boolean
|
|
467
|
+
exportsFinalName?: Array<[string, string]> | undefined
|
|
468
|
+
}
|
|
469
|
+
|
|
470
|
+
export interface JsBuildMetaDefaultObjectRedirectWarn {
|
|
471
|
+
redirectWarn: JsDefaultObjectRedirectWarnObject
|
|
472
|
+
}
|
|
473
|
+
|
|
448
474
|
export interface JsBuildTimeExecutionOption {
|
|
449
475
|
publicPath?: string
|
|
450
476
|
baseUri?: string
|
|
451
477
|
}
|
|
452
478
|
|
|
453
479
|
export interface JsCacheGroupTestCtx {
|
|
454
|
-
module:
|
|
480
|
+
module: JsModule
|
|
455
481
|
}
|
|
456
482
|
|
|
457
483
|
export interface JsChunk {
|
|
@@ -488,7 +514,7 @@ export interface JsChunkGroup {
|
|
|
488
514
|
}
|
|
489
515
|
|
|
490
516
|
export interface JsChunkGroupOrigin {
|
|
491
|
-
module?:
|
|
517
|
+
module?: JsModule | undefined
|
|
492
518
|
request?: string
|
|
493
519
|
}
|
|
494
520
|
|
|
@@ -518,6 +544,10 @@ export interface JsCreateData {
|
|
|
518
544
|
resource: string
|
|
519
545
|
}
|
|
520
546
|
|
|
547
|
+
export interface JsDefaultObjectRedirectWarnObject {
|
|
548
|
+
ignore: boolean
|
|
549
|
+
}
|
|
550
|
+
|
|
521
551
|
export interface JsDiagnostic {
|
|
522
552
|
message: string
|
|
523
553
|
help?: string
|
|
@@ -659,6 +689,7 @@ export interface JsLoaderContext {
|
|
|
659
689
|
loaderItems: Array<JsLoaderItem>
|
|
660
690
|
loaderIndex: number
|
|
661
691
|
loaderState: Readonly<JsLoaderState>
|
|
692
|
+
__internal__error?: JsRspackError
|
|
662
693
|
}
|
|
663
694
|
|
|
664
695
|
export interface JsLoaderItem {
|
|
@@ -669,26 +700,11 @@ export interface JsLoaderItem {
|
|
|
669
700
|
pitchExecuted: boolean
|
|
670
701
|
}
|
|
671
702
|
|
|
672
|
-
export enum JsLoaderState {
|
|
703
|
+
export declare enum JsLoaderState {
|
|
673
704
|
Pitching = 'Pitching',
|
|
674
705
|
Normal = 'Normal'
|
|
675
706
|
}
|
|
676
707
|
|
|
677
|
-
export interface JsModule {
|
|
678
|
-
context?: string
|
|
679
|
-
originalSource?: JsCompatSource
|
|
680
|
-
resource?: string
|
|
681
|
-
moduleIdentifier: string
|
|
682
|
-
nameForCondition?: string
|
|
683
|
-
request?: string
|
|
684
|
-
userRequest?: string
|
|
685
|
-
rawRequest?: string
|
|
686
|
-
factoryMeta?: JsFactoryMeta
|
|
687
|
-
type: string
|
|
688
|
-
layer?: string
|
|
689
|
-
useSourceMap?: boolean
|
|
690
|
-
}
|
|
691
|
-
|
|
692
708
|
export interface JsModuleDescriptor {
|
|
693
709
|
identifier: string
|
|
694
710
|
name: string
|
|
@@ -757,7 +773,7 @@ export interface JsRspackError {
|
|
|
757
773
|
hideStack?: boolean
|
|
758
774
|
}
|
|
759
775
|
|
|
760
|
-
export enum JsRspackSeverity {
|
|
776
|
+
export declare enum JsRspackSeverity {
|
|
761
777
|
Error = 'Error',
|
|
762
778
|
Warn = 'Warn'
|
|
763
779
|
}
|
|
@@ -1032,17 +1048,10 @@ export interface JsStatsWarning {
|
|
|
1032
1048
|
}
|
|
1033
1049
|
|
|
1034
1050
|
export interface JsTap {
|
|
1035
|
-
function:
|
|
1051
|
+
function: any
|
|
1036
1052
|
stage: number
|
|
1037
1053
|
}
|
|
1038
1054
|
|
|
1039
|
-
export interface NodeFS {
|
|
1040
|
-
writeFile: (...args: any[]) => any
|
|
1041
|
-
removeFile: (...args: any[]) => any
|
|
1042
|
-
mkdir: (...args: any[]) => any
|
|
1043
|
-
mkdirp: (...args: any[]) => any
|
|
1044
|
-
}
|
|
1045
|
-
|
|
1046
1055
|
export interface NodeFsStats {
|
|
1047
1056
|
isFile: boolean
|
|
1048
1057
|
isDirectory: boolean
|
|
@@ -1204,10 +1213,10 @@ export interface RawContainerReferencePluginOptions {
|
|
|
1204
1213
|
}
|
|
1205
1214
|
|
|
1206
1215
|
export interface RawContextReplacementPluginOptions {
|
|
1207
|
-
resourceRegExp:
|
|
1216
|
+
resourceRegExp: RegExp
|
|
1208
1217
|
newContentResource?: string
|
|
1209
1218
|
newContentRecursive?: boolean
|
|
1210
|
-
newContentRegExp?:
|
|
1219
|
+
newContentRegExp?: RegExp
|
|
1211
1220
|
newContentCreateContextMap?: Record<string, string>
|
|
1212
1221
|
}
|
|
1213
1222
|
|
|
@@ -1282,6 +1291,35 @@ export interface RawCssParserOptions {
|
|
|
1282
1291
|
namedExports?: boolean
|
|
1283
1292
|
}
|
|
1284
1293
|
|
|
1294
|
+
export interface RawDllEntryPluginOptions {
|
|
1295
|
+
context: string
|
|
1296
|
+
entries: Array<string>
|
|
1297
|
+
name: string
|
|
1298
|
+
}
|
|
1299
|
+
|
|
1300
|
+
export interface RawDllManifest {
|
|
1301
|
+
content: Record<string, RawDllManifestContentItem>
|
|
1302
|
+
name?: string
|
|
1303
|
+
type?: string
|
|
1304
|
+
}
|
|
1305
|
+
|
|
1306
|
+
export interface RawDllManifestContentItem {
|
|
1307
|
+
buildMeta?: JsBuildMeta
|
|
1308
|
+
exports?: string[] | true
|
|
1309
|
+
id?: string
|
|
1310
|
+
}
|
|
1311
|
+
|
|
1312
|
+
export interface RawDllReferenceAgencyPluginOptions {
|
|
1313
|
+
context?: string
|
|
1314
|
+
name?: string
|
|
1315
|
+
extensions: Array<string>
|
|
1316
|
+
scope?: string
|
|
1317
|
+
sourceType?: string
|
|
1318
|
+
type: string
|
|
1319
|
+
content?: Record<string, RawDllManifestContentItem>
|
|
1320
|
+
manifest?: RawDllManifest
|
|
1321
|
+
}
|
|
1322
|
+
|
|
1285
1323
|
export interface RawDraft {
|
|
1286
1324
|
customMedia: boolean
|
|
1287
1325
|
}
|
|
@@ -1360,6 +1398,10 @@ export interface RawFallbackCacheGroupOptions {
|
|
|
1360
1398
|
automaticNameDelimiter?: string
|
|
1361
1399
|
}
|
|
1362
1400
|
|
|
1401
|
+
export interface RawFlagAllModulesAsUsedPluginOptions {
|
|
1402
|
+
explanation: string
|
|
1403
|
+
}
|
|
1404
|
+
|
|
1363
1405
|
export interface RawFuncUseCtx {
|
|
1364
1406
|
resource?: string
|
|
1365
1407
|
realResource?: string
|
|
@@ -1481,13 +1523,22 @@ export interface RawJavascriptParserOptions {
|
|
|
1481
1523
|
}
|
|
1482
1524
|
|
|
1483
1525
|
export interface RawLazyCompilationOption {
|
|
1484
|
-
module: (err: Error | null, arg: RawModuleArg) =>
|
|
1526
|
+
module: ((err: Error | null, arg: RawModuleArg) => RawModuleInfo)
|
|
1485
1527
|
test?: RawLazyCompilationTest
|
|
1486
1528
|
entries: boolean
|
|
1487
1529
|
imports: boolean
|
|
1488
1530
|
cacheable: boolean
|
|
1489
1531
|
}
|
|
1490
1532
|
|
|
1533
|
+
export interface RawLibManifestPluginOptions {
|
|
1534
|
+
context?: string
|
|
1535
|
+
entryOnly?: boolean
|
|
1536
|
+
name?: JsFilename
|
|
1537
|
+
path: JsFilename
|
|
1538
|
+
format?: boolean
|
|
1539
|
+
type?: string
|
|
1540
|
+
}
|
|
1541
|
+
|
|
1491
1542
|
export interface RawLightningCssBrowsers {
|
|
1492
1543
|
android?: number
|
|
1493
1544
|
chrome?: number
|
|
@@ -1738,11 +1789,6 @@ export interface RawProvideOptions {
|
|
|
1738
1789
|
strictVersion?: boolean
|
|
1739
1790
|
}
|
|
1740
1791
|
|
|
1741
|
-
export interface RawRegex {
|
|
1742
|
-
source: string
|
|
1743
|
-
flags: string
|
|
1744
|
-
}
|
|
1745
|
-
|
|
1746
1792
|
export interface RawRelated {
|
|
1747
1793
|
sourceMap?: string
|
|
1748
1794
|
}
|
|
@@ -1816,13 +1862,13 @@ export interface RawRspackFuture {
|
|
|
1816
1862
|
export interface RawRuleSetCondition {
|
|
1817
1863
|
type: RawRuleSetConditionType
|
|
1818
1864
|
string?: string
|
|
1819
|
-
regexp?:
|
|
1865
|
+
regexp?: RegExp
|
|
1820
1866
|
logical?: Array<RawRuleSetLogicalConditions>
|
|
1821
1867
|
array?: Array<RawRuleSetCondition>
|
|
1822
1868
|
func?: (value: string) => boolean
|
|
1823
1869
|
}
|
|
1824
1870
|
|
|
1825
|
-
export enum RawRuleSetConditionType {
|
|
1871
|
+
export declare enum RawRuleSetConditionType {
|
|
1826
1872
|
string = 'string',
|
|
1827
1873
|
regexp = 'regexp',
|
|
1828
1874
|
logical = 'logical',
|
|
@@ -1931,9 +1977,9 @@ export interface RawTrustedTypes {
|
|
|
1931
1977
|
* Author Donny/강동윤
|
|
1932
1978
|
* Copyright (c)
|
|
1933
1979
|
*/
|
|
1934
|
-
export function registerGlobalTrace(filter: string, layer: "chrome" | "logger"| "console", output: string): void
|
|
1980
|
+
export declare function registerGlobalTrace(filter: string, layer: "chrome" | "logger"| "console", output: string): void
|
|
1935
1981
|
|
|
1936
|
-
export enum RegisterJsTapKind {
|
|
1982
|
+
export declare enum RegisterJsTapKind {
|
|
1937
1983
|
CompilerThisCompilation = 0,
|
|
1938
1984
|
CompilerCompilation = 1,
|
|
1939
1985
|
CompilerMake = 2,
|
|
@@ -2032,4 +2078,3 @@ export interface ThreadsafeNodeFS {
|
|
|
2032
2078
|
stat: (name: string) => Promise<NodeFsStats | void> | NodeFsStats | void
|
|
2033
2079
|
lstat: (name: string) => Promise<NodeFsStats | void> | NodeFsStats | void
|
|
2034
2080
|
}
|
|
2035
|
-
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rspack/binding",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.1",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Node binding for rspack",
|
|
6
6
|
"main": "binding.js",
|
|
@@ -17,22 +17,22 @@
|
|
|
17
17
|
"bugs": "https://github.com/web-infra-dev/rspack/issues",
|
|
18
18
|
"repository": "web-infra-dev/rspack",
|
|
19
19
|
"devDependencies": {
|
|
20
|
-
"@napi-rs/cli": "3.0.0-alpha.
|
|
20
|
+
"@napi-rs/cli": "3.0.0-alpha.64",
|
|
21
21
|
"typescript": "^5.6.3"
|
|
22
22
|
},
|
|
23
23
|
"napi": {
|
|
24
24
|
"binaryName": "rspack"
|
|
25
25
|
},
|
|
26
26
|
"optionalDependencies": {
|
|
27
|
-
"@rspack/binding-
|
|
28
|
-
"@rspack/binding-
|
|
29
|
-
"@rspack/binding-linux-arm64-gnu": "1.1.
|
|
30
|
-
"@rspack/binding-linux-arm64-musl": "1.1.
|
|
31
|
-
"@rspack/binding-win32-ia32-msvc": "1.1.
|
|
32
|
-
"@rspack/binding-
|
|
33
|
-
"@rspack/binding-win32-x64-msvc": "1.1.
|
|
34
|
-
"@rspack/binding-
|
|
35
|
-
"@rspack/binding-linux-x64-
|
|
27
|
+
"@rspack/binding-darwin-arm64": "1.1.1",
|
|
28
|
+
"@rspack/binding-win32-arm64-msvc": "1.1.1",
|
|
29
|
+
"@rspack/binding-linux-arm64-gnu": "1.1.1",
|
|
30
|
+
"@rspack/binding-linux-arm64-musl": "1.1.1",
|
|
31
|
+
"@rspack/binding-win32-ia32-msvc": "1.1.1",
|
|
32
|
+
"@rspack/binding-linux-x64-musl": "1.1.1",
|
|
33
|
+
"@rspack/binding-win32-x64-msvc": "1.1.1",
|
|
34
|
+
"@rspack/binding-darwin-x64": "1.1.1",
|
|
35
|
+
"@rspack/binding-linux-x64-gnu": "1.1.1"
|
|
36
36
|
},
|
|
37
37
|
"scripts": {
|
|
38
38
|
"build:debug": "node scripts/build.js",
|