@rspack/core 1.3.7 → 1.3.9
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 +77 -57
- package/compiled/browserslist/package.json +1 -1
- package/compiled/graceful-fs/index.js +8 -8
- package/compiled/zod/index.d.ts +2 -1772
- package/compiled/zod/index.js +35 -35
- package/compiled/zod/lib/ZodError.d.ts +164 -0
- package/compiled/zod/lib/__tests__/Mocker.d.ts +17 -0
- package/compiled/zod/lib/benchmarks/datetime.d.ts +5 -0
- package/compiled/zod/lib/benchmarks/discriminatedUnion.d.ts +5 -0
- package/compiled/zod/lib/benchmarks/index.d.ts +1 -0
- package/compiled/zod/lib/benchmarks/ipv4.d.ts +5 -0
- package/compiled/zod/lib/benchmarks/object.d.ts +5 -0
- package/compiled/zod/lib/benchmarks/primitives.d.ts +5 -0
- package/compiled/zod/lib/benchmarks/realworld.d.ts +5 -0
- package/compiled/zod/lib/benchmarks/string.d.ts +5 -0
- package/compiled/zod/lib/benchmarks/union.d.ts +5 -0
- package/compiled/zod/lib/errors.d.ts +5 -0
- package/compiled/zod/lib/external.d.ts +6 -0
- package/compiled/zod/lib/helpers/enumUtil.d.ts +8 -0
- package/compiled/zod/lib/helpers/errorUtil.d.ts +9 -0
- package/compiled/zod/lib/helpers/parseUtil.d.ts +78 -0
- package/compiled/zod/lib/helpers/partialUtil.d.ts +8 -0
- package/compiled/zod/lib/helpers/typeAliases.d.ts +2 -0
- package/compiled/zod/lib/helpers/util.d.ts +82 -0
- package/compiled/zod/lib/index.d.ts +4 -0
- package/compiled/zod/lib/locales/en.d.ts +3 -0
- package/compiled/zod/lib/standard-schema.d.ts +102 -0
- package/compiled/zod/lib/types.d.ts +1062 -0
- package/compiled/zod/package.json +1 -1
- package/dist/ChunkGroup.d.ts +10 -0
- package/dist/builtin-loader/swc/pluginImport.d.ts +1 -1
- package/dist/builtin-loader/swc/types.d.ts +632 -631
- package/dist/builtin-plugin/html-plugin/hooks.d.ts +3 -1
- package/dist/builtin-plugin/html-plugin/options.d.ts +7 -3
- package/dist/builtin-plugin/html-plugin/plugin.d.ts +0 -1
- package/dist/config/types.d.ts +11 -3
- package/dist/config/utils.d.ts +1 -1
- package/dist/config/zod.d.ts +77 -77
- package/dist/exports.d.ts +5 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +644 -597
- package/dist/setupEnv.d.ts +1 -0
- package/dist/stats/statsFactoryUtils.d.ts +1 -0
- package/dist/swc.d.ts +5 -0
- package/package.json +11 -11
@@ -11,7 +11,9 @@ export type HtmlRspackPluginHooks = {
|
|
11
11
|
beforeAssetTagGeneration: liteTapable.AsyncSeriesWaterfallHook<[
|
12
12
|
JsBeforeAssetTagGenerationData & ExtraPluginHookData
|
13
13
|
]>;
|
14
|
-
alterAssetTags: liteTapable.AsyncSeriesWaterfallHook<[
|
14
|
+
alterAssetTags: liteTapable.AsyncSeriesWaterfallHook<[
|
15
|
+
JsAlterAssetTagsData & ExtraPluginHookData
|
16
|
+
]>;
|
15
17
|
alterAssetTagGroups: liteTapable.AsyncSeriesWaterfallHook<[
|
16
18
|
JsAlterAssetTagGroupsData & ExtraPluginHookData
|
17
19
|
]>;
|
@@ -72,8 +72,12 @@ export type HtmlRspackPluginOptions = {
|
|
72
72
|
* If `true` then append a unique Rspack compilation hash to all included scripts and CSS files. This is useful for cache busting.
|
73
73
|
*/
|
74
74
|
hash?: boolean;
|
75
|
+
/**
|
76
|
+
* Any other options will be passed by hooks.
|
77
|
+
*/
|
78
|
+
[key: string]: any;
|
75
79
|
};
|
76
80
|
export declare function validateHtmlPluginOptions(options: HtmlRspackPluginOptions): string | null;
|
77
|
-
export declare const getPluginOptions: (compilation: Compilation) =>
|
78
|
-
export declare const setPluginOptions: (compilation: Compilation, options: HtmlRspackPluginOptions) => void;
|
79
|
-
export declare const cleanPluginOptions: (compilation: Compilation) => void;
|
81
|
+
export declare const getPluginOptions: (compilation: Compilation, uid: number) => any;
|
82
|
+
export declare const setPluginOptions: (compilation: Compilation, uid: number, options: HtmlRspackPluginOptions) => void;
|
83
|
+
export declare const cleanPluginOptions: (compilation: Compilation, uid: number) => void;
|
@@ -18,7 +18,6 @@ declare const HtmlRspackPlugin: typeof HtmlRspackPluginImpl & {
|
|
18
18
|
*/
|
19
19
|
getHooks: (compilation: Compilation) => HtmlRspackPluginHooks;
|
20
20
|
getCompilationHooks: (compilation: Compilation) => HtmlRspackPluginHooks;
|
21
|
-
getCompilationOptions: (compilation: Compilation) => HtmlRspackPluginOptions | void;
|
22
21
|
createHtmlTagObject: (tagName: string, attributes?: Record<string, string | boolean>, innerHTML?: string | undefined) => JsHtmlPluginTag;
|
23
22
|
version: number;
|
24
23
|
};
|
package/dist/config/types.d.ts
CHANGED
@@ -176,7 +176,7 @@ export type ChunkLoadingGlobal = string;
|
|
176
176
|
export type EnabledLibraryTypes = string[];
|
177
177
|
/** Whether delete all files in the output directory. */
|
178
178
|
export type Clean = boolean | {
|
179
|
-
keep?: string;
|
179
|
+
keep?: string | RegExp | ((path: string) => boolean);
|
180
180
|
};
|
181
181
|
/** Output JavaScript files as module type. */
|
182
182
|
export type OutputModule = boolean;
|
@@ -620,7 +620,7 @@ export type RuleSetRule = {
|
|
620
620
|
resourceFragment?: RuleSetCondition;
|
621
621
|
/** Matches all modules that match this resource against the Resource's query. */
|
622
622
|
resourceQuery?: RuleSetCondition;
|
623
|
-
/** Matches
|
623
|
+
/** Matches modules based on [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Guides/MIME_types) instead of file extension. It's primarily useful for data URI module */
|
624
624
|
mimetype?: RuleSetCondition;
|
625
625
|
/** Matches all modules that match this resource, and will match against the Resource's scheme. */
|
626
626
|
scheme?: RuleSetCondition;
|
@@ -1848,6 +1848,10 @@ export type LazyCompilationOptions = {
|
|
1848
1848
|
* Options for incremental builds.
|
1849
1849
|
*/
|
1850
1850
|
export type Incremental = {
|
1851
|
+
/**
|
1852
|
+
* Warning if there are cases that not friendly for incremental
|
1853
|
+
*/
|
1854
|
+
silent?: boolean;
|
1851
1855
|
/**
|
1852
1856
|
* Enable incremental make.
|
1853
1857
|
*/
|
@@ -1909,6 +1913,10 @@ export type Incremental = {
|
|
1909
1913
|
*/
|
1910
1914
|
emitAssets?: boolean;
|
1911
1915
|
};
|
1916
|
+
/**
|
1917
|
+
* Presets for incremental
|
1918
|
+
*/
|
1919
|
+
export type IncrementalPresets = boolean | "none" | "safe" | "advance" | "advance-silent";
|
1912
1920
|
/**
|
1913
1921
|
* Options for experiments.buildHttp
|
1914
1922
|
*/
|
@@ -1963,7 +1971,7 @@ export type Experiments = {
|
|
1963
1971
|
/**
|
1964
1972
|
* Enable incremental builds.
|
1965
1973
|
*/
|
1966
|
-
incremental?:
|
1974
|
+
incremental?: IncrementalPresets | Incremental;
|
1967
1975
|
/**
|
1968
1976
|
* Enable multi-threaded code splitting algorithm.
|
1969
1977
|
*/
|
package/dist/config/utils.d.ts
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
import
|
1
|
+
import { type IssueData, type ParseReturnType, ZodType, type ZodTypeDef, z } from "../../compiled/zod";
|
2
2
|
import type { RspackOptions } from "./types";
|
3
3
|
export type ZodCrossFieldsOptions = ZodTypeDef & {
|
4
4
|
patterns: Array<{
|