@rspack-debug/browser 2.0.8 → 2.1.0-rc.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/dist/ModuleGraph.d.ts +1 -0
- package/dist/RuntimeGlobals.d.ts +7 -6
- package/dist/builtin-plugin/RsdoctorPlugin.d.ts +1 -0
- package/dist/config/adapterRuleUse.d.ts +1 -1
- package/dist/config/defaults.d.ts +1 -1
- package/dist/config/normalization.d.ts +11 -8
- package/dist/config/types.d.ts +27 -8
- package/dist/index.js +4502 -4064
- package/dist/loader-runner/index.d.ts +9 -10
- package/dist/napi-binding.d.ts +8 -0
- package/dist/node/NodeWatchFileSystem.d.ts +3 -1
- package/dist/rspack.d.ts +1 -1
- package/dist/trace/index.d.ts +1 -0
- package/dist/util/identifier.d.ts +0 -1
- package/dist/wasi-worker-browser.mjs +642 -345
- package/package.json +8 -8
|
@@ -1,15 +1,18 @@
|
|
|
1
1
|
import { type JsLoaderContext, type JsLoaderItem } from '../binding';
|
|
2
2
|
import type { Compiler } from '../Compiler';
|
|
3
|
+
type LoaderObjectOptions = string | (object & {
|
|
4
|
+
ident?: unknown;
|
|
5
|
+
}) | null;
|
|
3
6
|
export declare class LoaderObject {
|
|
4
7
|
request: string;
|
|
5
8
|
path: string;
|
|
6
9
|
query: string;
|
|
7
10
|
fragment: string;
|
|
8
|
-
options?:
|
|
9
|
-
ident: string;
|
|
10
|
-
normal?: Function;
|
|
11
|
-
pitch?: Function;
|
|
12
|
-
raw?: boolean;
|
|
11
|
+
options?: LoaderObjectOptions;
|
|
12
|
+
ident: string | null;
|
|
13
|
+
normal?: Function | null;
|
|
14
|
+
pitch?: Function | null;
|
|
15
|
+
raw?: boolean | null;
|
|
13
16
|
type?: 'module' | 'commonjs';
|
|
14
17
|
parallel?: boolean | {
|
|
15
18
|
maxWorkers?: number;
|
|
@@ -29,8 +32,4 @@ export declare class LoaderObject {
|
|
|
29
32
|
static __to_binding(loader: LoaderObject): JsLoaderItem;
|
|
30
33
|
}
|
|
31
34
|
export declare function runLoaders(compiler: Compiler, context: JsLoaderContext): Promise<JsLoaderContext>;
|
|
32
|
-
export
|
|
33
|
-
path: string;
|
|
34
|
-
query: string;
|
|
35
|
-
fragment: string;
|
|
36
|
-
};
|
|
35
|
+
export {};
|
package/dist/napi-binding.d.ts
CHANGED
|
@@ -69,6 +69,7 @@ export interface NormalModule extends Module {
|
|
|
69
69
|
readonly loaders: JsLoaderItem[];
|
|
70
70
|
get matchResource(): string | undefined;
|
|
71
71
|
set matchResource(val: string | undefined);
|
|
72
|
+
get error(): RspackError | undefined;
|
|
72
73
|
}
|
|
73
74
|
|
|
74
75
|
export interface ConcatenatedModule extends Module {
|
|
@@ -411,6 +412,7 @@ export declare class JsModuleGraph {
|
|
|
411
412
|
getModule(dependency: Dependency): Module | null
|
|
412
413
|
getResolvedModule(dependency: Dependency): Module | null
|
|
413
414
|
getUsedExports(module: Module, runtime: string | string[]): boolean | Array<string> | null
|
|
415
|
+
getProvidedExports(module: Module): true | string[] | null
|
|
414
416
|
getIssuer(module: Module): Module | null
|
|
415
417
|
getExportsInfo(module: Module): JsExportsInfo
|
|
416
418
|
getConnection(dependency: Dependency): ModuleGraphConnection | null
|
|
@@ -1187,6 +1189,7 @@ export interface JsRsdoctorModuleGraph {
|
|
|
1187
1189
|
dependencies: Array<JsRsdoctorDependency>
|
|
1188
1190
|
chunkModules: Array<JsRsdoctorChunkModules>
|
|
1189
1191
|
connectionsOnlyImports: Array<JsRsdoctorConnectionsOnlyImport>
|
|
1192
|
+
exportUsageEdges: Array<[number, Array<string> | null, number, Array<string> | null]>
|
|
1190
1193
|
}
|
|
1191
1194
|
|
|
1192
1195
|
export interface JsRsdoctorModuleGraphModule {
|
|
@@ -2275,6 +2278,7 @@ export interface RawExperiments {
|
|
|
2275
2278
|
deferImport: boolean
|
|
2276
2279
|
sourceImport: boolean
|
|
2277
2280
|
pureFunctions: boolean
|
|
2281
|
+
runtimeMode?: "webpack" | "rspack"
|
|
2278
2282
|
}
|
|
2279
2283
|
|
|
2280
2284
|
export interface RawExposeOptions {
|
|
@@ -2476,6 +2480,7 @@ export interface RawJavascriptParserOptions {
|
|
|
2476
2480
|
overrideStrict?: string
|
|
2477
2481
|
importMeta?: string
|
|
2478
2482
|
commonjsMagicComments?: boolean
|
|
2483
|
+
createRequire?: boolean | string
|
|
2479
2484
|
commonjs?: boolean | { exports?: boolean | 'skipInEsm' }
|
|
2480
2485
|
deferImport?: boolean
|
|
2481
2486
|
sourceImport?: boolean
|
|
@@ -2939,6 +2944,7 @@ export interface RawRsdoctorPluginOptions {
|
|
|
2939
2944
|
moduleGraphFeatures: boolean | Array<'graph' | 'ids' | 'sources'>
|
|
2940
2945
|
chunkGraphFeatures: boolean | Array<'graph' | 'assets'>
|
|
2941
2946
|
sourceMapFeatures?: { module?: boolean; cheap?: boolean } | undefined
|
|
2947
|
+
exportUsageGraph?: boolean
|
|
2942
2948
|
}
|
|
2943
2949
|
|
|
2944
2950
|
export interface RawRslibPluginOptions {
|
|
@@ -3080,6 +3086,8 @@ export interface RawStatsOptions {
|
|
|
3080
3086
|
export interface RawStorageOptions {
|
|
3081
3087
|
type: "filesystem"
|
|
3082
3088
|
directory: string
|
|
3089
|
+
maxAge: number
|
|
3090
|
+
maxGenerations: number
|
|
3083
3091
|
}
|
|
3084
3092
|
|
|
3085
3093
|
export interface RawSubresourceIntegrityPluginOptions {
|
|
@@ -9,10 +9,12 @@
|
|
|
9
9
|
*/
|
|
10
10
|
import type Watchpack from 'watchpack';
|
|
11
11
|
import type { FileSystemInfoEntry, InputFileSystem, Watcher, WatchFileSystem } from '../util/fs';
|
|
12
|
+
type WatchpackInstance = InstanceType<typeof Watchpack>;
|
|
12
13
|
export default class NodeWatchFileSystem implements WatchFileSystem {
|
|
13
14
|
inputFileSystem: InputFileSystem;
|
|
14
15
|
watcherOptions: Watchpack.WatchOptions;
|
|
15
|
-
watcher?:
|
|
16
|
+
watcher?: WatchpackInstance;
|
|
16
17
|
constructor(inputFileSystem: InputFileSystem);
|
|
17
18
|
watch(files: Iterable<string>, directories: Iterable<string>, missing: Iterable<string>, startTime: number, options: Watchpack.WatchOptions, callback: (error: Error | null, fileTimeInfoEntries: Map<string, FileSystemInfoEntry | 'ignore'>, contextTimeInfoEntries: Map<string, FileSystemInfoEntry | 'ignore'>, changedFiles: Set<string>, removedFiles: Set<string>) => void, callbackUndelayed: (fileName: string, changeTime: number) => void): Watcher;
|
|
18
19
|
}
|
|
20
|
+
export {};
|
package/dist/rspack.d.ts
CHANGED
|
@@ -14,7 +14,7 @@ import { MultiCompiler, type MultiRspackOptions } from './MultiCompiler';
|
|
|
14
14
|
import MultiStats from './MultiStats';
|
|
15
15
|
import { Stats } from './Stats';
|
|
16
16
|
declare function createMultiCompiler(options: MultiRspackOptions): MultiCompiler;
|
|
17
|
-
declare function createCompiler(userOptions: RspackOptions): Compiler;
|
|
17
|
+
declare function createCompiler(userOptions: RspackOptions, compilerIndex?: number): Compiler;
|
|
18
18
|
declare function rspack(options: MultiRspackOptions): MultiCompiler;
|
|
19
19
|
declare function rspack(options: RspackOptions): Compiler;
|
|
20
20
|
declare function rspack(options: MultiRspackOptions | RspackOptions): MultiCompiler | Compiler;
|
package/dist/trace/index.d.ts
CHANGED
|
@@ -27,6 +27,7 @@ export declare class JavaScriptTracer {
|
|
|
27
27
|
*/
|
|
28
28
|
static initJavaScriptTrace(layer: string, output: string): Promise<void>;
|
|
29
29
|
static uuid(): number;
|
|
30
|
+
static isEnabled(): boolean;
|
|
30
31
|
static initCpuProfiler(): void;
|
|
31
32
|
/**
|
|
32
33
|
* only first call take effects, subsequent calls will be ignored
|