Skip to content

Commit

Permalink
chore: update api check
Browse files Browse the repository at this point in the history
  • Loading branch information
SyMind committed Sep 20, 2024
1 parent 75a1ad7 commit b75cce4
Showing 1 changed file with 48 additions and 15 deletions.
63 changes: 48 additions & 15 deletions packages/rspack/etc/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ import { JsChunkGroup } from '@rspack/binding';
import { JsChunkGroupOrigin } from '@rspack/binding';
import type { JsCodegenerationResult } from '@rspack/binding';
import { JsCompilation } from '@rspack/binding';
import type { JsContextModuleFactoryAfterResolveData } from '@rspack/binding';
import type { JsCreateData } from '@rspack/binding';
import type { JsFactoryMeta } from '@rspack/binding';
import { JsHtmlPluginTag } from '@rspack/binding';
Expand Down Expand Up @@ -1560,20 +1561,51 @@ class ContextModuleFactory {
}

// @public (undocumented)
type ContextModuleFactoryAfterResolveResult = false | {
resource: string;
context: string;
request: string;
regExp?: RegExp;
dependencies: Array<any>;
};
class ContextModuleFactoryAfterResolveData {
constructor(data: JsContextModuleFactoryAfterResolveData);
// (undocumented)
static __from_binding(binding: JsContextModuleFactoryAfterResolveData): ContextModuleFactoryAfterResolveData;
// (undocumented)
static __to_binding(data: ContextModuleFactoryAfterResolveData): JsContextModuleFactoryAfterResolveData;
// (undocumented)
get context(): string;
set context(val: string);
// (undocumented)
get dependencies(): Dependency[];
// (undocumented)
get recursive(): boolean;
set recursive(val: boolean);
// (undocumented)
get regExp(): RegExp | undefined;
set regExp(val: RegExp | undefined);
// (undocumented)
get request(): string;
set request(val: string);
// (undocumented)
get resource(): string;
set resource(val: string);
}

// @public (undocumented)
type ContextModuleFactoryAfterResolveResult = false | ContextModuleFactoryAfterResolveData;

// @public (undocumented)
type ContextModuleFactoryBeforeResolveResult = false | {
context: string;
request?: string;
};

// @public (undocumented)
export const ContextReplacementPlugin: {
new (resourceRegExp: RegExp, newContentResource?: any, newContentRecursive?: any, newContentRegExp?: any): {
name: BuiltinPluginName;
_args: [resourceRegExp: RegExp, newContentResource?: any, newContentRecursive?: any, newContentRegExp?: any];
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;
raw(compiler: Compiler_2): BuiltinPlugin;
apply(compiler: Compiler_2): void;
};
};

// @public (undocumented)
export const CopyRspackPlugin: {
new (copy: CopyRspackPluginOptions): {
Expand Down Expand Up @@ -10070,6 +10102,7 @@ declare namespace rspackExports {
EvalSourceMapDevToolPlugin,
EvalDevToolModulePlugin,
CssExtractRspackPlugin,
ContextReplacementPlugin,
SwcLoaderEnvConfig,
SwcLoaderEsParserConfig,
SwcLoaderJscConfig,
Expand Down Expand Up @@ -11572,6 +11605,7 @@ export const rspackOptions: z.ZodObject<{
errorsSpace: z.ZodOptional<z.ZodNumber>;
warningsSpace: z.ZodOptional<z.ZodNumber>;
}, "strict", z.ZodTypeAny, {
source?: boolean | undefined;
publicPath?: boolean | undefined;
hash?: boolean | undefined;
all?: boolean | undefined;
Expand All @@ -11598,7 +11632,6 @@ export const rspackOptions: z.ZodObject<{
builtAt?: boolean | undefined;
moduleAssets?: boolean | undefined;
nestedModules?: boolean | undefined;
source?: boolean | undefined;
logging?: boolean | "log" | "info" | "verbose" | "none" | "error" | "warn" | undefined;
loggingDebug?: string | boolean | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean) | (string | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean))[] | undefined;
loggingTrace?: boolean | undefined;
Expand Down Expand Up @@ -11649,6 +11682,7 @@ export const rspackOptions: z.ZodObject<{
errorsSpace?: number | undefined;
warningsSpace?: number | undefined;
}, {
source?: boolean | undefined;
publicPath?: boolean | undefined;
hash?: boolean | undefined;
all?: boolean | undefined;
Expand All @@ -11675,7 +11709,6 @@ export const rspackOptions: z.ZodObject<{
builtAt?: boolean | undefined;
moduleAssets?: boolean | undefined;
nestedModules?: boolean | undefined;
source?: boolean | undefined;
logging?: boolean | "log" | "info" | "verbose" | "none" | "error" | "warn" | undefined;
loggingDebug?: string | boolean | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean) | (string | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean))[] | undefined;
loggingTrace?: boolean | undefined;
Expand Down Expand Up @@ -13395,6 +13428,7 @@ export const rspackOptions: z.ZodObject<{
} | undefined;
watch?: boolean | undefined;
stats?: boolean | "verbose" | "normal" | "none" | "errors-only" | "errors-warnings" | "minimal" | "detailed" | "summary" | {
source?: boolean | undefined;
publicPath?: boolean | undefined;
hash?: boolean | undefined;
all?: boolean | undefined;
Expand All @@ -13421,7 +13455,6 @@ export const rspackOptions: z.ZodObject<{
builtAt?: boolean | undefined;
moduleAssets?: boolean | undefined;
nestedModules?: boolean | undefined;
source?: boolean | undefined;
logging?: boolean | "log" | "info" | "verbose" | "none" | "error" | "warn" | undefined;
loggingDebug?: string | boolean | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean) | (string | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean))[] | undefined;
loggingTrace?: boolean | undefined;
Expand Down Expand Up @@ -13969,6 +14002,7 @@ export const rspackOptions: z.ZodObject<{
} | undefined;
watch?: boolean | undefined;
stats?: boolean | "verbose" | "normal" | "none" | "errors-only" | "errors-warnings" | "minimal" | "detailed" | "summary" | {
source?: boolean | undefined;
publicPath?: boolean | undefined;
hash?: boolean | undefined;
all?: boolean | undefined;
Expand All @@ -13995,7 +14029,6 @@ export const rspackOptions: z.ZodObject<{
builtAt?: boolean | undefined;
moduleAssets?: boolean | undefined;
nestedModules?: boolean | undefined;
source?: boolean | undefined;
logging?: boolean | "log" | "info" | "verbose" | "none" | "error" | "warn" | undefined;
loggingDebug?: string | boolean | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean) | (string | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean))[] | undefined;
loggingTrace?: boolean | undefined;
Expand Down Expand Up @@ -14783,6 +14816,7 @@ const statsOptions: z.ZodObject<{
errorsSpace: z.ZodOptional<z.ZodNumber>;
warningsSpace: z.ZodOptional<z.ZodNumber>;
}, "strict", z.ZodTypeAny, {
source?: boolean | undefined;
publicPath?: boolean | undefined;
hash?: boolean | undefined;
all?: boolean | undefined;
Expand All @@ -14809,7 +14843,6 @@ const statsOptions: z.ZodObject<{
builtAt?: boolean | undefined;
moduleAssets?: boolean | undefined;
nestedModules?: boolean | undefined;
source?: boolean | undefined;
logging?: boolean | "log" | "info" | "verbose" | "none" | "error" | "warn" | undefined;
loggingDebug?: string | boolean | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean) | (string | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean))[] | undefined;
loggingTrace?: boolean | undefined;
Expand Down Expand Up @@ -14860,6 +14893,7 @@ const statsOptions: z.ZodObject<{
errorsSpace?: number | undefined;
warningsSpace?: number | undefined;
}, {
source?: boolean | undefined;
publicPath?: boolean | undefined;
hash?: boolean | undefined;
all?: boolean | undefined;
Expand All @@ -14886,7 +14920,6 @@ const statsOptions: z.ZodObject<{
builtAt?: boolean | undefined;
moduleAssets?: boolean | undefined;
nestedModules?: boolean | undefined;
source?: boolean | undefined;
logging?: boolean | "log" | "info" | "verbose" | "none" | "error" | "warn" | undefined;
loggingDebug?: string | boolean | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean) | (string | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean))[] | undefined;
loggingTrace?: boolean | undefined;
Expand Down Expand Up @@ -15050,6 +15083,7 @@ const statsValue: z.ZodUnion<[z.ZodUnion<[z.ZodBoolean, z.ZodEnum<["normal", "no
errorsSpace: z.ZodOptional<z.ZodNumber>;
warningsSpace: z.ZodOptional<z.ZodNumber>;
}, "strict", z.ZodTypeAny, {
source?: boolean | undefined;
publicPath?: boolean | undefined;
hash?: boolean | undefined;
all?: boolean | undefined;
Expand All @@ -15076,7 +15110,6 @@ const statsValue: z.ZodUnion<[z.ZodUnion<[z.ZodBoolean, z.ZodEnum<["normal", "no
builtAt?: boolean | undefined;
moduleAssets?: boolean | undefined;
nestedModules?: boolean | undefined;
source?: boolean | undefined;
logging?: boolean | "log" | "info" | "verbose" | "none" | "error" | "warn" | undefined;
loggingDebug?: string | boolean | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean) | (string | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean))[] | undefined;
loggingTrace?: boolean | undefined;
Expand Down Expand Up @@ -15127,6 +15160,7 @@ const statsValue: z.ZodUnion<[z.ZodUnion<[z.ZodBoolean, z.ZodEnum<["normal", "no
errorsSpace?: number | undefined;
warningsSpace?: number | undefined;
}, {
source?: boolean | undefined;
publicPath?: boolean | undefined;
hash?: boolean | undefined;
all?: boolean | undefined;
Expand All @@ -15153,7 +15187,6 @@ const statsValue: z.ZodUnion<[z.ZodUnion<[z.ZodBoolean, z.ZodEnum<["normal", "no
builtAt?: boolean | undefined;
moduleAssets?: boolean | undefined;
nestedModules?: boolean | undefined;
source?: boolean | undefined;
logging?: boolean | "log" | "info" | "verbose" | "none" | "error" | "warn" | undefined;
loggingDebug?: string | boolean | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean) | (string | RegExp | ((args_0: string, ...args_1: unknown[]) => boolean))[] | undefined;
loggingTrace?: boolean | undefined;
Expand Down

0 comments on commit b75cce4

Please sign in to comment.