@rspack/core 1.0.0-alpha.2 → 1.0.0-alpha.4
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/compiled/browserslist/index.js +17 -17
- package/compiled/enhanced-resolve/index.js +107 -107
- package/compiled/graceful-fs/index.js +8 -8
- package/compiled/json-parse-even-better-errors/index.js +2 -2
- package/compiled/neo-async/index.js +2 -2
- package/compiled/watchpack/index.js +15 -15
- package/compiled/webpack-sources/index.js +76 -76
- package/compiled/zod/index.js +30 -30
- package/compiled/zod-validation-error/index.js +6 -6
- package/dist/ChunkGraph.d.ts +1 -1
- package/dist/Compilation.d.ts +9 -9
- package/dist/Compilation.js +27 -24
- package/dist/Compiler.d.ts +6 -6
- package/dist/Compiler.js +5 -6
- package/dist/ContextModuleFactory.d.ts +1 -1
- package/dist/ErrorHelpers.d.ts +16 -7
- package/dist/ErrorHelpers.js +34 -33
- package/dist/ExecuteModulePlugin.js +1 -1
- package/dist/FileSystem.d.ts +2 -2
- package/dist/Module.d.ts +5 -5
- package/dist/Module.js +3 -6
- package/dist/MultiCompiler.d.ts +3 -3
- package/dist/MultiCompiler.js +1 -1
- package/dist/MultiStats.d.ts +2 -2
- package/dist/MultiWatching.d.ts +2 -2
- package/dist/NormalModule.d.ts +1 -1
- package/dist/NormalModuleFactory.d.ts +1 -1
- package/dist/Resolver.d.ts +19 -0
- package/dist/Resolver.js +39 -0
- package/dist/ResolverFactory.d.ts +12 -46
- package/dist/ResolverFactory.js +55 -120
- package/dist/RspackError.d.ts +1 -1
- package/dist/RuntimeGlobals.d.ts +1 -1
- package/dist/RuntimeGlobals.js +3 -3
- package/dist/Stats.d.ts +2 -2
- package/dist/Stats.js +4 -4
- package/dist/Template.js +2 -2
- package/dist/Watching.d.ts +3 -3
- package/dist/builtin-loader/swc/index.d.ts +0 -2
- package/dist/builtin-loader/swc/index.js +1 -3
- package/dist/builtin-loader/swc/pluginImport.d.ts +17 -1
- package/dist/builtin-loader/swc/react.d.ts +11 -1
- package/dist/builtin-plugin/APIPlugin.d.ts +3 -3
- package/dist/builtin-plugin/ArrayPushCallbackChunkFormatPlugin.d.ts +3 -3
- package/dist/builtin-plugin/AssetModulesPlugin.d.ts +3 -3
- package/dist/builtin-plugin/AsyncWebAssemblyModulesPlugin.d.ts +3 -3
- package/dist/builtin-plugin/BannerPlugin.d.ts +25 -4
- package/dist/builtin-plugin/BundlerInfoRspackPlugin.d.ts +4 -4
- package/dist/builtin-plugin/ChunkPrefetchPreloadPlugin.d.ts +3 -3
- package/dist/builtin-plugin/CommonJsChunkFormatPlugin.d.ts +3 -3
- package/dist/builtin-plugin/CopyRspackPlugin.d.ts +4 -4
- package/dist/builtin-plugin/CssModulesPlugin.d.ts +3 -3
- package/dist/builtin-plugin/DataUriPlugin.d.ts +3 -3
- package/dist/builtin-plugin/DefinePlugin.d.ts +10 -4
- package/dist/builtin-plugin/DefinePlugin.js +42 -8
- package/dist/builtin-plugin/DeterministicChunkIdsPlugin.d.ts +3 -3
- package/dist/builtin-plugin/DeterministicModuleIdsPlugin.d.ts +3 -3
- package/dist/builtin-plugin/DynamicEntryPlugin.d.ts +5 -5
- package/dist/builtin-plugin/ElectronTargetPlugin.d.ts +3 -3
- package/dist/builtin-plugin/EnableChunkLoadingPlugin.d.ts +3 -3
- package/dist/builtin-plugin/EnableLibraryPlugin.d.ts +2 -2
- package/dist/builtin-plugin/EnableWasmLoadingPlugin.d.ts +3 -3
- package/dist/builtin-plugin/EnsureChunkConditionsPlugin.d.ts +3 -3
- package/dist/builtin-plugin/EntryPlugin.d.ts +5 -5
- package/dist/builtin-plugin/EntryPlugin.js +1 -1
- package/dist/builtin-plugin/EvalDevToolModulePlugin.d.ts +4 -4
- package/dist/builtin-plugin/EvalSourceMapDevToolPlugin.d.ts +5 -5
- package/dist/builtin-plugin/ExternalsPlugin.d.ts +22 -6
- package/dist/builtin-plugin/FetchCompileAsyncWasmPlugin.d.ts +3 -3
- package/dist/builtin-plugin/FileUriPlugin.d.ts +3 -3
- package/dist/builtin-plugin/FlagDependencyExportsPlugin.d.ts +3 -3
- package/dist/builtin-plugin/FlagDependencyUsagePlugin.d.ts +3 -3
- package/dist/builtin-plugin/HotModuleReplacementPlugin.d.ts +2 -2
- package/dist/builtin-plugin/HtmlRspackPlugin.d.ts +19 -4
- package/dist/builtin-plugin/HttpExternalsRspackPlugin.d.ts +4 -4
- package/dist/builtin-plugin/IgnorePlugin.d.ts +4 -4
- package/dist/builtin-plugin/InferAsyncModulesPlugin.d.ts +3 -3
- package/dist/builtin-plugin/JavascriptModulesPlugin.d.ts +2 -2
- package/dist/builtin-plugin/JsLoaderRspackPlugin.d.ts +4 -4
- package/dist/builtin-plugin/JsonModulesPlugin.d.ts +3 -3
- package/dist/builtin-plugin/LightningCssMiminizerRspackPlugin.d.ts +4 -4
- package/dist/builtin-plugin/LimitChunkCountPlugin.d.ts +4 -4
- package/dist/builtin-plugin/MangleExportsPlugin.d.ts +3 -3
- package/dist/builtin-plugin/MergeDuplicateChunksPlugin.d.ts +3 -3
- package/dist/builtin-plugin/ModuleChunkFormatPlugin.d.ts +3 -3
- package/dist/builtin-plugin/ModuleConcatenationPlugin.d.ts +3 -3
- package/dist/builtin-plugin/NamedChunkIdsPlugin.d.ts +3 -3
- package/dist/builtin-plugin/NamedModuleIdsPlugin.d.ts +3 -3
- package/dist/builtin-plugin/NaturalChunkIdsPlugin.d.ts +3 -3
- package/dist/builtin-plugin/NaturalModuleIdsPlugin.d.ts +3 -3
- package/dist/builtin-plugin/NodeTargetPlugin.d.ts +3 -3
- package/dist/builtin-plugin/ProgressPlugin.d.ts +4 -4
- package/dist/builtin-plugin/ProvidePlugin.d.ts +3 -3
- package/dist/builtin-plugin/RealContentHashPlugin.d.ts +3 -3
- package/dist/builtin-plugin/RemoveEmptyChunksPlugin.d.ts +3 -3
- package/dist/builtin-plugin/RuntimeChunkPlugin.d.ts +4 -4
- package/dist/builtin-plugin/RuntimePlugin.d.ts +3 -3
- package/dist/builtin-plugin/SideEffectsFlagPlugin.d.ts +3 -3
- package/dist/builtin-plugin/SizeLimitsPlugin.d.ts +9 -4
- package/dist/builtin-plugin/SourceMapDevToolPlugin.d.ts +4 -4
- package/dist/builtin-plugin/SplitChunksPlugin.d.ts +3 -3
- package/dist/builtin-plugin/SwcCssMinimizerPlugin.d.ts +12 -4
- package/dist/builtin-plugin/SwcCssMinimizerPlugin.js +7 -1
- package/dist/builtin-plugin/SwcJsMinimizerPlugin.d.ts +4 -4
- package/dist/builtin-plugin/SwcJsMinimizerPlugin.js +2 -2
- package/dist/builtin-plugin/WarnCaseSensitiveModulesPlugin.d.ts +3 -3
- package/dist/builtin-plugin/WebWorkerTemplatePlugin.d.ts +3 -3
- package/dist/builtin-plugin/WorkerPlugin.d.ts +3 -3
- package/dist/builtin-plugin/WorkerPlugin.js +5 -1
- package/dist/builtin-plugin/base.d.ts +6 -6
- package/dist/builtin-plugin/base.js +4 -4
- package/dist/builtin-plugin/css-extract/index.d.ts +1 -1
- package/dist/builtin-plugin/css-extract/loader.js +15 -5
- package/dist/builtin-plugin/css-extract/utils.d.ts +1 -1
- package/dist/builtin-plugin/index.d.ts +1 -7
- package/dist/builtin-plugin/index.js +3 -17
- package/dist/builtin-plugin/lazy-compilation/lazyCompilation.d.ts +11 -17
- package/dist/builtin-plugin/lazy-compilation/plugin.d.ts +2 -2
- package/dist/config/adapter.d.ts +5 -4
- package/dist/config/adapter.js +23 -11
- package/dist/config/adapterRuleUse.d.ts +7 -7
- package/dist/config/adapterRuleUse.js +1 -1
- package/dist/config/browserslistTargetHandler.js +1 -1
- package/dist/config/defaults.d.ts +1 -1
- package/dist/config/defaults.js +4 -3
- package/dist/config/zod.d.ts +491 -384
- package/dist/config/zod.js +44 -42
- package/dist/container/ContainerPlugin.d.ts +3 -3
- package/dist/container/ContainerReferencePlugin.d.ts +4 -4
- package/dist/container/ModuleFederationPlugin.d.ts +2 -2
- package/dist/container/ModuleFederationPlugin.js +2 -2
- package/dist/container/ModuleFederationPluginV1.d.ts +5 -5
- package/dist/container/ModuleFederationRuntimePlugin.d.ts +3 -3
- package/dist/container/default.runtime.js +1 -1
- package/dist/lib/EntryOptionPlugin.d.ts +2 -2
- package/dist/lib/NormalModuleReplacementPlugin.d.ts +2 -2
- package/dist/loader-runner/index.d.ts +2 -2
- package/dist/loader-runner/index.js +38 -51
- package/dist/loader-runner/loadLoader.js +1 -1
- package/dist/logging/runtime.js +1 -1
- package/dist/node/NodeTemplatePlugin.d.ts +1 -1
- package/dist/node/NodeWatchFileSystem.d.ts +1 -1
- package/dist/rspack.d.ts +3 -3
- package/dist/rspack.js +1 -1
- package/dist/rspackOptionsApply.d.ts +1 -1
- package/dist/rspackOptionsApply.js +1 -19
- package/dist/sharing/ConsumeSharedPlugin.d.ts +2 -2
- package/dist/sharing/ConsumeSharedPlugin.js +1 -1
- package/dist/sharing/ProvideSharedPlugin.d.ts +2 -2
- package/dist/sharing/SharePlugin.d.ts +1 -1
- package/dist/sharing/ShareRuntimePlugin.d.ts +2 -2
- package/dist/stats/DefaultStatsFactoryPlugin.js +246 -46
- package/dist/stats/DefaultStatsPresetPlugin.js +17 -17
- package/dist/stats/DefaultStatsPrinterPlugin.js +1 -1
- package/dist/stats/StatsFactory.d.ts +2 -2
- package/dist/stats/statsFactoryUtils.d.ts +16 -1
- package/dist/util/SplitChunkSize.d.ts +1 -1
- package/dist/util/bindingVersionCheck.js +1 -1
- package/dist/util/comparators.d.ts +1 -1
- package/dist/util/fs.d.ts +1 -1
- package/dist/util/identifier.d.ts +65 -62
- package/dist/util/identifier.js +30 -55
- package/dist/util/index.d.ts +1 -1
- package/dist/util/index.js +4 -2
- package/dist/util/validate.d.ts +1 -1
- package/package.json +7 -34
package/dist/Module.js
CHANGED
|
@@ -10,7 +10,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
10
10
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
11
11
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
12
12
|
};
|
|
13
|
-
var _Module_inner, _Module_originalSource, _CodeGenerationResult_inner
|
|
13
|
+
var _Module_inner, _Module_originalSource, _CodeGenerationResult_inner;
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.CodeGenerationResults = exports.CodeGenerationResult = exports.Module = void 0;
|
|
16
16
|
const source_1 = require("./util/source");
|
|
@@ -22,6 +22,7 @@ class Module {
|
|
|
22
22
|
_Module_inner.set(this, void 0);
|
|
23
23
|
_Module_originalSource.set(this, void 0);
|
|
24
24
|
__classPrivateFieldSet(this, _Module_inner, module, "f");
|
|
25
|
+
this.type = module.type;
|
|
25
26
|
this.context = module.context;
|
|
26
27
|
this.resource = module.resource;
|
|
27
28
|
this.request = module.request;
|
|
@@ -69,10 +70,6 @@ class CodeGenerationResult {
|
|
|
69
70
|
exports.CodeGenerationResult = CodeGenerationResult;
|
|
70
71
|
_CodeGenerationResult_inner = new WeakMap();
|
|
71
72
|
class CodeGenerationResults {
|
|
72
|
-
constructor(
|
|
73
|
-
_CodeGenerationResults_inner.set(this, void 0);
|
|
74
|
-
__classPrivateFieldSet(this, _CodeGenerationResults_inner, result, "f");
|
|
75
|
-
}
|
|
73
|
+
constructor(_result) { }
|
|
76
74
|
}
|
|
77
75
|
exports.CodeGenerationResults = CodeGenerationResults;
|
|
78
|
-
_CodeGenerationResults_inner = new WeakMap();
|
package/dist/MultiCompiler.d.ts
CHANGED
|
@@ -8,11 +8,11 @@
|
|
|
8
8
|
* https://github.com/webpack/webpack/blob/main/LICENSE
|
|
9
9
|
*/
|
|
10
10
|
import * as liteTapable from "@rspack/lite-tapable";
|
|
11
|
-
import { Compiler, RspackOptions } from ".";
|
|
11
|
+
import type { Compiler, RspackOptions } from ".";
|
|
12
12
|
import MultiStats from "./MultiStats";
|
|
13
13
|
import MultiWatching from "./MultiWatching";
|
|
14
|
-
import { WatchOptions } from "./config";
|
|
15
|
-
import { WatchFileSystem } from "./util/fs";
|
|
14
|
+
import type { WatchOptions } from "./config";
|
|
15
|
+
import type { WatchFileSystem } from "./util/fs";
|
|
16
16
|
export interface MultiCompilerOptions {
|
|
17
17
|
/**
|
|
18
18
|
* how many Compilers are allows to run at the same time in parallel
|
package/dist/MultiCompiler.js
CHANGED
|
@@ -67,7 +67,7 @@ class MultiCompiler {
|
|
|
67
67
|
};
|
|
68
68
|
this.compilers = compilers;
|
|
69
69
|
this._options = {
|
|
70
|
-
parallelism: options?.parallelism ||
|
|
70
|
+
parallelism: options?.parallelism || Number.POSITIVE_INFINITY
|
|
71
71
|
};
|
|
72
72
|
this.dependencies = new WeakMap();
|
|
73
73
|
this.running = false;
|
package/dist/MultiStats.d.ts
CHANGED
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
* Copyright (c) JS Foundation and other contributors
|
|
8
8
|
* https://github.com/webpack/webpack/blob/main/LICENSE
|
|
9
9
|
*/
|
|
10
|
-
import { Stats } from "./Stats";
|
|
11
|
-
import { StatsCompilation } from "./stats/statsFactoryUtils";
|
|
10
|
+
import type { Stats } from "./Stats";
|
|
11
|
+
import type { StatsCompilation } from "./stats/statsFactoryUtils";
|
|
12
12
|
export default class MultiStats {
|
|
13
13
|
#private;
|
|
14
14
|
stats: Stats[];
|
package/dist/MultiWatching.d.ts
CHANGED
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
* Copyright (c) JS Foundation and other contributors
|
|
8
8
|
* https://github.com/webpack/webpack/blob/main/LICENSE
|
|
9
9
|
*/
|
|
10
|
-
import { MultiCompiler } from "./MultiCompiler";
|
|
11
|
-
import { Watching } from "./Watching";
|
|
10
|
+
import type { MultiCompiler } from "./MultiCompiler";
|
|
11
|
+
import type { Watching } from "./Watching";
|
|
12
12
|
declare class MultiWatching {
|
|
13
13
|
watchings: Watching[];
|
|
14
14
|
compiler: MultiCompiler;
|
package/dist/NormalModule.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import * as liteTapable from "@rspack/lite-tapable";
|
|
3
3
|
import { Compilation } from "./Compilation";
|
|
4
|
-
import { LoaderContext } from "./config";
|
|
4
|
+
import type { LoaderContext } from "./config";
|
|
5
5
|
export declare class NormalModule {
|
|
6
6
|
static getCompilationHooks(compilation: Compilation): {
|
|
7
7
|
loader: liteTapable.SyncHook<[LoaderContext<{}>], void, {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type * as binding from "@rspack/binding";
|
|
2
2
|
import * as liteTapable from "@rspack/lite-tapable";
|
|
3
|
-
import { ResolveData, ResourceDataWithData } from "./Module";
|
|
3
|
+
import type { ResolveData, ResourceDataWithData } from "./Module";
|
|
4
4
|
export type NormalModuleCreateData = binding.JsNormalModuleFactoryCreateModuleArgs & {
|
|
5
5
|
settings: {};
|
|
6
6
|
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type * as binding from "@rspack/binding";
|
|
2
|
+
import { type Resolve } from "./config";
|
|
3
|
+
interface ResolveContext {
|
|
4
|
+
}
|
|
5
|
+
type ErrorWithDetail = Error & {
|
|
6
|
+
details?: string;
|
|
7
|
+
};
|
|
8
|
+
type ResolveOptionsWithDependencyType = Resolve & {
|
|
9
|
+
dependencyCategory?: string;
|
|
10
|
+
resolveToContext?: boolean;
|
|
11
|
+
};
|
|
12
|
+
export declare class Resolver {
|
|
13
|
+
binding: binding.JsResolver;
|
|
14
|
+
constructor(binding: binding.JsResolver);
|
|
15
|
+
resolveSync(context: object, path: string, request: string): string | false;
|
|
16
|
+
resolve(context: object, path: string, request: string, resolveContext: ResolveContext, callback: (err: null | ErrorWithDetail, res?: string | false) => void): void;
|
|
17
|
+
withOptions({ dependencyCategory, resolveToContext, ...resolve }: ResolveOptionsWithDependencyType): Resolver;
|
|
18
|
+
}
|
|
19
|
+
export {};
|
package/dist/Resolver.js
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Resolver = void 0;
|
|
4
|
+
const config_1 = require("./config");
|
|
5
|
+
function isString(value) {
|
|
6
|
+
return typeof value === "string";
|
|
7
|
+
}
|
|
8
|
+
class Resolver {
|
|
9
|
+
constructor(binding) {
|
|
10
|
+
this.binding = binding;
|
|
11
|
+
}
|
|
12
|
+
resolveSync(context, path, request) {
|
|
13
|
+
return this.binding.resolveSync(path, request);
|
|
14
|
+
}
|
|
15
|
+
resolve(context, path, request, resolveContext, callback) {
|
|
16
|
+
try {
|
|
17
|
+
const res = this.binding.resolveSync(path, request);
|
|
18
|
+
callback(null, res);
|
|
19
|
+
}
|
|
20
|
+
catch (err) {
|
|
21
|
+
callback(err);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
withOptions({ dependencyCategory, resolveToContext, ...resolve }) {
|
|
25
|
+
const rawResolve = (0, config_1.getRawResolve)(resolve);
|
|
26
|
+
// TODO: rspack_resolver is unimplemented regex
|
|
27
|
+
if (Array.isArray(rawResolve.restrictions)) {
|
|
28
|
+
rawResolve.restrictions =
|
|
29
|
+
rawResolve.restrictions.filter(isString);
|
|
30
|
+
}
|
|
31
|
+
const binding = this.binding.withOptions({
|
|
32
|
+
dependencyCategory,
|
|
33
|
+
resolveToContext,
|
|
34
|
+
...rawResolve
|
|
35
|
+
});
|
|
36
|
+
return new Resolver(binding);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
exports.Resolver = Resolver;
|
|
@@ -1,48 +1,14 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
/** @type {HookMap<SyncHook<[Resolver, ResolveOptions, ResolveOptionsWithDependencyType]>>} */
|
|
7
|
-
resolver: HookMap<SyncHook<[Resolver, ResolveOptions, ResolveOptionsWithDependencyType]>>;
|
|
8
|
-
}>;
|
|
9
|
-
/** @type {Map<string, ResolverCache>} */
|
|
10
|
-
cache: Map<string, ResolverCache>;
|
|
11
|
-
/**
|
|
12
|
-
* @param {string} type type of resolver
|
|
13
|
-
* @param {ResolveOptionsWithDependencyType=} resolveOptions options
|
|
14
|
-
* @returns {ResolverWithOptions} the resolver
|
|
15
|
-
*/
|
|
16
|
-
get(type: string, resolveOptions?: ResolveOptionsWithDependencyType | undefined): ResolverWithOptions;
|
|
17
|
-
/**
|
|
18
|
-
* @param {string} type type of resolver
|
|
19
|
-
* @param {ResolveOptionsWithDependencyType} resolveOptionsWithDepType options
|
|
20
|
-
* @returns {ResolverWithOptions} the resolver
|
|
21
|
-
*/
|
|
22
|
-
_create(type: string, resolveOptionsWithDepType: ResolveOptionsWithDependencyType): ResolverWithOptions;
|
|
23
|
-
}
|
|
24
|
-
declare namespace ResolverFactory {
|
|
25
|
-
export { ResolveOptions, Resolver, WebpackResolveOptions, ResolvePluginInstance, ResolveOptionsWithDependencyType, WithOptions, ResolverWithOptions, ResolverCache };
|
|
26
|
-
}
|
|
27
|
-
import { HookMap } from "@rspack/lite-tapable";
|
|
28
|
-
import { SyncWaterfallHook } from "@rspack/lite-tapable";
|
|
29
|
-
type ResolveOptionsWithDependencyType = WebpackResolveOptions & {
|
|
30
|
-
dependencyType?: string;
|
|
1
|
+
import * as binding from "@rspack/binding";
|
|
2
|
+
import { Resolver } from "./Resolver";
|
|
3
|
+
import { type Resolve } from "./config";
|
|
4
|
+
type ResolveOptionsWithDependencyType = Resolve & {
|
|
5
|
+
dependencyCategory?: string;
|
|
31
6
|
resolveToContext?: boolean;
|
|
32
7
|
};
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
};
|
|
40
|
-
type ResolverWithOptions = Resolver & WithOptions;
|
|
41
|
-
type WebpackResolveOptions = any;
|
|
42
|
-
type ResolvePluginInstance = any;
|
|
43
|
-
type WithOptions = {
|
|
44
|
-
/**
|
|
45
|
-
* create a resolver with additional/different options
|
|
46
|
-
*/
|
|
47
|
-
withOptions: (arg0: Partial<ResolveOptionsWithDependencyType>) => ResolverWithOptions;
|
|
48
|
-
};
|
|
8
|
+
export declare class ResolverFactory {
|
|
9
|
+
#private;
|
|
10
|
+
static __to_binding(resolver_factory: ResolverFactory): binding.JsResolverFactory;
|
|
11
|
+
constructor();
|
|
12
|
+
get(type: string, resolveOptions?: ResolveOptionsWithDependencyType): Resolver;
|
|
13
|
+
}
|
|
14
|
+
export {};
|
package/dist/ResolverFactory.js
CHANGED
|
@@ -1,126 +1,61 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The following code is modified based on
|
|
3
|
-
* https://github.com/webpack/webpack/blob/4b4ca3b/lib/ResolverFactory.js
|
|
4
|
-
*
|
|
5
|
-
* MIT Licensed
|
|
6
|
-
* Author Tobias Koppers @sokra
|
|
7
|
-
* Copyright (c) JS Foundation and other contributors
|
|
8
|
-
* https://github.com/webpack/webpack/blob/main/LICENSE
|
|
9
|
-
*/
|
|
10
1
|
"use strict";
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
// /** @typedef {import("../declarations/WebpackOptions").ResolveOptions} WebpackResolveOptions */
|
|
17
|
-
// /** @typedef {import("../declarations/WebpackOptions").ResolvePluginInstance} ResolvePluginInstance */
|
|
18
|
-
/** @typedef {any} WebpackResolveOptions */
|
|
19
|
-
/** @typedef {any} ResolvePluginInstance */
|
|
20
|
-
/** @typedef {WebpackResolveOptions & {dependencyType?: string, resolveToContext?: boolean }} ResolveOptionsWithDependencyType */
|
|
21
|
-
/**
|
|
22
|
-
* @typedef {Object} WithOptions
|
|
23
|
-
* @property {function(Partial<ResolveOptionsWithDependencyType>): ResolverWithOptions} withOptions create a resolver with additional/different options
|
|
24
|
-
*/
|
|
25
|
-
/** @typedef {Resolver & WithOptions} ResolverWithOptions */
|
|
26
|
-
// need to be hoisted on module level for caching identity
|
|
27
|
-
const EMPTY_RESOLVE_OPTIONS = {};
|
|
28
|
-
/**
|
|
29
|
-
* @param {ResolveOptionsWithDependencyType} resolveOptionsWithDepType enhanced options
|
|
30
|
-
* @returns {ResolveOptions} merged options
|
|
31
|
-
*/
|
|
32
|
-
const convertToResolveOptions = resolveOptionsWithDepType => {
|
|
33
|
-
const { dependencyType, plugins, ...remaining } = resolveOptionsWithDepType;
|
|
34
|
-
// check type compat
|
|
35
|
-
/** @type {Partial<ResolveOptions>} */
|
|
36
|
-
const partialOptions = {
|
|
37
|
-
...remaining,
|
|
38
|
-
plugins: plugins &&
|
|
39
|
-
/** @type {ResolvePluginInstance[]} */ (
|
|
40
|
-
// @ts-expect-error
|
|
41
|
-
plugins.filter(item => item !== "..."))
|
|
42
|
-
};
|
|
43
|
-
if (!partialOptions.fileSystem) {
|
|
44
|
-
throw new Error("fileSystem is missing in resolveOptions, but it's required for enhanced-resolve");
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
45
7
|
}
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
51
24
|
};
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
25
|
+
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
26
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
|
27
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
28
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
29
|
+
};
|
|
30
|
+
var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
|
|
31
|
+
if (kind === "m") throw new TypeError("Private method is not writable");
|
|
32
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
|
|
33
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
34
|
+
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
|
35
|
+
};
|
|
36
|
+
var _ResolverFactory_binding;
|
|
37
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
38
|
+
exports.ResolverFactory = void 0;
|
|
39
|
+
const binding = __importStar(require("@rspack/binding"));
|
|
40
|
+
const Resolver_1 = require("./Resolver");
|
|
41
|
+
const config_1 = require("./config");
|
|
42
|
+
class ResolverFactory {
|
|
43
|
+
static __to_binding(resolver_factory) {
|
|
44
|
+
return __classPrivateFieldGet(resolver_factory, _ResolverFactory_binding, "f");
|
|
67
45
|
}
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
* @returns {ResolverWithOptions} the resolver
|
|
72
|
-
*/
|
|
73
|
-
get(type, resolveOptions = EMPTY_RESOLVE_OPTIONS) {
|
|
74
|
-
let typedCaches = this.cache.get(type);
|
|
75
|
-
if (!typedCaches) {
|
|
76
|
-
typedCaches = {
|
|
77
|
-
direct: new WeakMap(),
|
|
78
|
-
stringified: new Map()
|
|
79
|
-
};
|
|
80
|
-
this.cache.set(type, typedCaches);
|
|
81
|
-
}
|
|
82
|
-
const cachedResolver = typedCaches.direct.get(resolveOptions);
|
|
83
|
-
if (cachedResolver) {
|
|
84
|
-
return cachedResolver;
|
|
85
|
-
}
|
|
86
|
-
const ident = JSON.stringify(resolveOptions);
|
|
87
|
-
const resolver = typedCaches.stringified.get(ident);
|
|
88
|
-
if (resolver) {
|
|
89
|
-
typedCaches.direct.set(resolveOptions, resolver);
|
|
90
|
-
return resolver;
|
|
91
|
-
}
|
|
92
|
-
const newResolver = this._create(type, resolveOptions);
|
|
93
|
-
typedCaches.direct.set(resolveOptions, newResolver);
|
|
94
|
-
typedCaches.stringified.set(ident, newResolver);
|
|
95
|
-
return newResolver;
|
|
46
|
+
constructor() {
|
|
47
|
+
_ResolverFactory_binding.set(this, void 0);
|
|
48
|
+
__classPrivateFieldSet(this, _ResolverFactory_binding, new binding.JsResolverFactory(), "f");
|
|
96
49
|
}
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
const resolveOptions = convertToResolveOptions(this.hooks.resolveOptions.for(type).call(resolveOptionsWithDepType));
|
|
106
|
-
const resolver = /** @type {ResolverWithOptions} */ (Factory.createResolver(resolveOptions));
|
|
107
|
-
if (!resolver) {
|
|
108
|
-
throw new Error("No resolver created");
|
|
109
|
-
}
|
|
110
|
-
/** @type {WeakMap<Partial<ResolveOptionsWithDependencyType>, ResolverWithOptions>} */
|
|
111
|
-
const childCache = new WeakMap();
|
|
112
|
-
resolver.withOptions = options => {
|
|
113
|
-
const cacheEntry = childCache.get(options);
|
|
114
|
-
if (cacheEntry !== undefined)
|
|
115
|
-
return cacheEntry;
|
|
116
|
-
const mergedOptions = cachedCleverMerge(originalResolveOptions, options);
|
|
117
|
-
const resolver = this.get(type, mergedOptions);
|
|
118
|
-
childCache.set(options, resolver);
|
|
119
|
-
return resolver;
|
|
120
|
-
};
|
|
121
|
-
this.hooks.resolver
|
|
122
|
-
.for(type)
|
|
123
|
-
.call(resolver, resolveOptions, originalResolveOptions);
|
|
124
|
-
return resolver;
|
|
50
|
+
get(type, resolveOptions) {
|
|
51
|
+
const { dependencyCategory, resolveToContext, ...resolve } = resolveOptions || {};
|
|
52
|
+
const binding = __classPrivateFieldGet(this, _ResolverFactory_binding, "f").get(type, {
|
|
53
|
+
...(0, config_1.getRawResolve)(resolve),
|
|
54
|
+
dependencyCategory,
|
|
55
|
+
resolveToContext
|
|
56
|
+
});
|
|
57
|
+
return new Resolver_1.Resolver(binding);
|
|
125
58
|
}
|
|
126
|
-
}
|
|
59
|
+
}
|
|
60
|
+
exports.ResolverFactory = ResolverFactory;
|
|
61
|
+
_ResolverFactory_binding = new WeakMap();
|
package/dist/RspackError.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as binding from "@rspack/binding";
|
|
1
|
+
import type * as binding from "@rspack/binding";
|
|
2
2
|
export type RspackError = binding.JsRspackError;
|
|
3
3
|
export declare class JsDiagnostic {
|
|
4
4
|
static __to_binding(error: Error | RspackError, severity: binding.JsRspackSeverity): binding.JsDiagnostic;
|
package/dist/RuntimeGlobals.d.ts
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* Copyright (c) JS Foundation and other contributors
|
|
8
8
|
* https://github.com/webpack/webpack/blob/main/LICENSE
|
|
9
9
|
*/
|
|
10
|
-
import { JsRuntimeGlobals } from "@rspack/binding";
|
|
10
|
+
import type { JsRuntimeGlobals } from "@rspack/binding";
|
|
11
11
|
export declare function __from_binding_runtime_globals(runtimeRequirements: JsRuntimeGlobals): Set<string>;
|
|
12
12
|
export declare function __to_binding_runtime_globals(runtimeRequirements: Set<string>): JsRuntimeGlobals;
|
|
13
13
|
export declare const RuntimeGlobals: {
|
package/dist/RuntimeGlobals.js
CHANGED
|
@@ -13,7 +13,7 @@ exports.RuntimeGlobals = exports.__to_binding_runtime_globals = exports.__from_b
|
|
|
13
13
|
const REVERSE_RUNTIME_GLOBALS = new Map();
|
|
14
14
|
function __from_binding_runtime_globals(runtimeRequirements) {
|
|
15
15
|
const res = new Set();
|
|
16
|
-
for (
|
|
16
|
+
for (const flag of runtimeRequirements.value) {
|
|
17
17
|
if (flag in exports.RuntimeGlobals) {
|
|
18
18
|
res.add(exports.RuntimeGlobals[flag]);
|
|
19
19
|
}
|
|
@@ -28,7 +28,7 @@ function __to_binding_runtime_globals(runtimeRequirements) {
|
|
|
28
28
|
const res = {
|
|
29
29
|
value: []
|
|
30
30
|
};
|
|
31
|
-
for (
|
|
31
|
+
for (const flag of Array.from(runtimeRequirements)) {
|
|
32
32
|
const item = REVERSE_RUNTIME_GLOBALS.get(flag);
|
|
33
33
|
if (typeof item === "string") {
|
|
34
34
|
res.value.push(item);
|
|
@@ -352,6 +352,6 @@ exports.RuntimeGlobals = {
|
|
|
352
352
|
*/
|
|
353
353
|
asyncModule: "__webpack_require__.a"
|
|
354
354
|
};
|
|
355
|
-
for (
|
|
355
|
+
for (const entry of Object.entries(exports.RuntimeGlobals)) {
|
|
356
356
|
REVERSE_RUNTIME_GLOBALS.set(entry[1], entry[0]);
|
|
357
357
|
}
|
package/dist/Stats.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Compilation } from "./Compilation";
|
|
2
|
-
import { StatsOptions, StatsValue } from "./config";
|
|
1
|
+
import type { Compilation } from "./Compilation";
|
|
2
|
+
import type { StatsOptions, StatsValue } from "./config";
|
|
3
3
|
import type { StatsCompilation } from "./stats/statsFactoryUtils";
|
|
4
4
|
export type { StatsAsset, StatsChunk, StatsCompilation, StatsError, StatsModule, StatsWarnings } from "./stats/statsFactoryUtils";
|
|
5
5
|
export declare class Stats {
|
package/dist/Stats.js
CHANGED
|
@@ -102,7 +102,7 @@ function normalizeStatsPreset(options) {
|
|
|
102
102
|
else if (!options)
|
|
103
103
|
return {};
|
|
104
104
|
else {
|
|
105
|
-
|
|
105
|
+
const obj = { ...presetToOptions(options.preset), ...options };
|
|
106
106
|
delete obj.preset;
|
|
107
107
|
return obj;
|
|
108
108
|
}
|
|
@@ -118,15 +118,15 @@ function presetToOptions(name) {
|
|
|
118
118
|
case "verbose":
|
|
119
119
|
return {
|
|
120
120
|
all: true,
|
|
121
|
-
modulesSpace:
|
|
121
|
+
modulesSpace: Number.POSITIVE_INFINITY
|
|
122
122
|
};
|
|
123
123
|
case "errors-only":
|
|
124
124
|
return {
|
|
125
125
|
all: false,
|
|
126
126
|
errors: true,
|
|
127
127
|
errorsCount: true,
|
|
128
|
-
logging: "error"
|
|
129
|
-
|
|
128
|
+
logging: "error",
|
|
129
|
+
moduleTrace: true
|
|
130
130
|
};
|
|
131
131
|
case "errors-warnings":
|
|
132
132
|
return {
|
package/dist/Template.js
CHANGED
|
@@ -246,8 +246,8 @@ class Template {
|
|
|
246
246
|
* or false if not every module has a number based id
|
|
247
247
|
*/
|
|
248
248
|
static getModulesArrayBounds(modules) {
|
|
249
|
-
let maxId =
|
|
250
|
-
let minId =
|
|
249
|
+
let maxId = Number.NEGATIVE_INFINITY;
|
|
250
|
+
let minId = Number.POSITIVE_INFINITY;
|
|
251
251
|
for (const module of modules) {
|
|
252
252
|
const moduleId = module.id;
|
|
253
253
|
if (typeof moduleId !== "number")
|
package/dist/Watching.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { Callback } from "@rspack/lite-tapable";
|
|
1
|
+
import type { Callback } from "@rspack/lite-tapable";
|
|
2
2
|
import type { Compiler } from ".";
|
|
3
3
|
import { Stats } from ".";
|
|
4
|
-
import { WatchOptions } from "./config";
|
|
5
|
-
import { Watcher } from "./util/fs";
|
|
4
|
+
import type { WatchOptions } from "./config";
|
|
5
|
+
import type { Watcher } from "./util/fs";
|
|
6
6
|
export declare class Watching {
|
|
7
7
|
#private;
|
|
8
8
|
watcher?: Watcher;
|
|
@@ -1,5 +1,3 @@
|
|
|
1
1
|
export { resolvePluginImport } from "./pluginImport";
|
|
2
2
|
export type { PluginImportOptions } from "./pluginImport";
|
|
3
|
-
export type { ReactOptions } from "./react";
|
|
4
|
-
export { resolveReact } from "./react";
|
|
5
3
|
export type { SwcLoaderEnvConfig, SwcLoaderEsParserConfig, SwcLoaderJscConfig, SwcLoaderModuleConfig, SwcLoaderOptions, SwcLoaderParserConfig, SwcLoaderTransformConfig, SwcLoaderTsParserConfig } from "./types";
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.resolvePluginImport = void 0;
|
|
4
4
|
var pluginImport_1 = require("./pluginImport");
|
|
5
5
|
Object.defineProperty(exports, "resolvePluginImport", { enumerable: true, get: function () { return pluginImport_1.resolvePluginImport; } });
|
|
6
|
-
var react_1 = require("./react");
|
|
7
|
-
Object.defineProperty(exports, "resolveReact", { enumerable: true, get: function () { return react_1.resolveReact; } });
|
|
@@ -1,4 +1,20 @@
|
|
|
1
|
-
|
|
1
|
+
type RawStyleConfig = {
|
|
2
|
+
styleLibraryDirectory?: string;
|
|
3
|
+
custom?: string;
|
|
4
|
+
css?: string;
|
|
5
|
+
bool?: boolean;
|
|
6
|
+
};
|
|
7
|
+
type RawPluginImportConfig = {
|
|
8
|
+
libraryName: string;
|
|
9
|
+
libraryDirectory?: string;
|
|
10
|
+
customName?: string;
|
|
11
|
+
customStyleName?: string;
|
|
12
|
+
style?: RawStyleConfig;
|
|
13
|
+
camelToDashComponentName?: boolean;
|
|
14
|
+
transformToDefaultImport?: boolean;
|
|
15
|
+
ignoreEsComponent?: Array<string>;
|
|
16
|
+
ignoreStyleComponent?: Array<string>;
|
|
17
|
+
};
|
|
2
18
|
type PluginImportConfig = {
|
|
3
19
|
libraryName: string;
|
|
4
20
|
libraryDirectory?: string;
|
|
@@ -1,4 +1,14 @@
|
|
|
1
|
-
|
|
1
|
+
type RawReactOptions = {
|
|
2
|
+
runtime?: "automatic" | "classic";
|
|
3
|
+
importSource?: string;
|
|
4
|
+
pragma?: string;
|
|
5
|
+
pragmaFrag?: string;
|
|
6
|
+
throwIfNamespace?: boolean;
|
|
7
|
+
development?: boolean;
|
|
8
|
+
useBuiltins?: boolean;
|
|
9
|
+
useSpread?: boolean;
|
|
10
|
+
refresh?: boolean;
|
|
11
|
+
};
|
|
2
12
|
declare function resolveReact(react: ReactOptions): RawReactOptions;
|
|
3
13
|
type ReactOptions = RawReactOptions | undefined;
|
|
4
14
|
export { resolveReact };
|
|
@@ -2,9 +2,9 @@ import { BuiltinPluginName } from "@rspack/binding";
|
|
|
2
2
|
export declare const APIPlugin: {
|
|
3
3
|
new (): {
|
|
4
4
|
name: BuiltinPluginName;
|
|
5
|
-
|
|
6
|
-
affectedHooks: "
|
|
7
|
-
raw(): import("@rspack/binding").BuiltinPlugin;
|
|
5
|
+
_args: [];
|
|
6
|
+
affectedHooks: "done" | "compilation" | "failed" | "environment" | "emit" | "make" | "compile" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
|
|
7
|
+
raw(compiler: import("../Compiler").Compiler): import("@rspack/binding").BuiltinPlugin;
|
|
8
8
|
apply(compiler: import("../Compiler").Compiler): void;
|
|
9
9
|
};
|
|
10
10
|
};
|
|
@@ -2,9 +2,9 @@ import { BuiltinPluginName } from "@rspack/binding";
|
|
|
2
2
|
export declare const ArrayPushCallbackChunkFormatPlugin: {
|
|
3
3
|
new (): {
|
|
4
4
|
name: BuiltinPluginName;
|
|
5
|
-
|
|
6
|
-
affectedHooks: "
|
|
7
|
-
raw(): import("@rspack/binding").BuiltinPlugin;
|
|
5
|
+
_args: [];
|
|
6
|
+
affectedHooks: "done" | "compilation" | "failed" | "environment" | "emit" | "make" | "compile" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
|
|
7
|
+
raw(compiler: import("../Compiler").Compiler): import("@rspack/binding").BuiltinPlugin;
|
|
8
8
|
apply(compiler: import("../Compiler").Compiler): void;
|
|
9
9
|
};
|
|
10
10
|
};
|
|
@@ -2,9 +2,9 @@ import { BuiltinPluginName } from "@rspack/binding";
|
|
|
2
2
|
export declare const AssetModulesPlugin: {
|
|
3
3
|
new (): {
|
|
4
4
|
name: BuiltinPluginName;
|
|
5
|
-
|
|
6
|
-
affectedHooks: "
|
|
7
|
-
raw(): import("@rspack/binding").BuiltinPlugin;
|
|
5
|
+
_args: [];
|
|
6
|
+
affectedHooks: "done" | "compilation" | "failed" | "environment" | "emit" | "make" | "compile" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
|
|
7
|
+
raw(compiler: import("../Compiler").Compiler): import("@rspack/binding").BuiltinPlugin;
|
|
8
8
|
apply(compiler: import("../Compiler").Compiler): void;
|
|
9
9
|
};
|
|
10
10
|
};
|
|
@@ -2,9 +2,9 @@ import { BuiltinPluginName } from "@rspack/binding";
|
|
|
2
2
|
export declare const AsyncWebAssemblyModulesPlugin: {
|
|
3
3
|
new (): {
|
|
4
4
|
name: BuiltinPluginName;
|
|
5
|
-
|
|
6
|
-
affectedHooks: "
|
|
7
|
-
raw(): import("@rspack/binding").BuiltinPlugin;
|
|
5
|
+
_args: [];
|
|
6
|
+
affectedHooks: "done" | "compilation" | "failed" | "environment" | "emit" | "make" | "compile" | "afterEmit" | "invalid" | "thisCompilation" | "afterDone" | "normalModuleFactory" | "contextModuleFactory" | "initialize" | "shouldEmit" | "infrastructureLog" | "beforeRun" | "run" | "assetEmitted" | "shutdown" | "watchRun" | "watchClose" | "afterEnvironment" | "afterPlugins" | "afterResolvers" | "beforeCompile" | "afterCompile" | "finishMake" | "entryOption" | undefined;
|
|
7
|
+
raw(compiler: import("../Compiler").Compiler): import("@rspack/binding").BuiltinPlugin;
|
|
8
8
|
apply(compiler: import("../Compiler").Compiler): void;
|
|
9
9
|
};
|
|
10
10
|
};
|