@hey-api/openapi-ts 0.87.0 → 0.87.2
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/README.md +3 -1
- package/dist/clients/angular/index.ts +0 -1
- package/dist/clients/angular/types.ts +0 -27
- package/dist/clients/axios/index.ts +0 -1
- package/dist/clients/axios/types.ts +0 -19
- package/dist/clients/fetch/index.ts +0 -1
- package/dist/clients/fetch/types.ts +0 -27
- package/dist/clients/ky/client.ts +339 -0
- package/dist/clients/ky/index.ts +24 -0
- package/dist/clients/ky/types.ts +271 -0
- package/dist/clients/ky/utils.ts +328 -0
- package/dist/clients/next/index.ts +0 -1
- package/dist/clients/next/types.ts +0 -19
- package/dist/clients/nuxt/index.ts +0 -1
- package/dist/clients/nuxt/types.ts +0 -12
- package/dist/clients/ofetch/index.ts +0 -1
- package/dist/clients/ofetch/types.ts +0 -27
- package/dist/{config-B2o9ax_a.d.cts → config-CQeoZYf_.d.cts} +769 -266
- package/dist/{config-oAoGatJ7.d.ts → config-U5JEpxGS.d.ts} +794 -291
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +28 -14
- package/dist/index.d.ts +28 -14
- package/dist/index.js +1 -1
- package/dist/internal.cjs +1 -1
- package/dist/internal.d.cts +1 -1
- package/dist/internal.d.ts +1 -1
- package/dist/internal.js +1 -1
- package/dist/openApi-CT-iM-D8.cjs +19 -0
- package/dist/openApi-CT-iM-D8.cjs.map +1 -0
- package/dist/openApi-HKXoyF4o.js +19 -0
- package/dist/openApi-HKXoyF4o.js.map +1 -0
- package/dist/run.cjs +1 -1
- package/dist/run.cjs.map +1 -1
- package/dist/run.js +1 -1
- package/dist/run.js.map +1 -1
- package/dist/{src-CTUbY-zd.js → src-Ba-zyEiS.js} +2 -2
- package/dist/{src-CTUbY-zd.js.map → src-Ba-zyEiS.js.map} +1 -1
- package/dist/{src-H1fIt1p4.cjs → src-CNO_U6s-.cjs} +2 -2
- package/dist/{src-H1fIt1p4.cjs.map → src-CNO_U6s-.cjs.map} +1 -1
- package/package.json +4 -3
- package/dist/openApi-BWD76jue.cjs +0 -21
- package/dist/openApi-BWD76jue.cjs.map +0 -1
- package/dist/openApi-DXfWYPpF.js +0 -21
- package/dist/openApi-DXfWYPpF.js.map +0 -1
|
@@ -2795,11 +2795,8 @@ type WalkOptions<T extends string = string> = {
|
|
|
2795
2795
|
type StringCase = 'camelCase' | 'PascalCase' | 'preserve' | 'snake_case' | 'SCREAMING_SNAKE_CASE';
|
|
2796
2796
|
type StringName = string | ((name: string) => string);
|
|
2797
2797
|
//#endregion
|
|
2798
|
-
//#region src/plugins/@angular/common/api.d.ts
|
|
2799
|
-
type IApi$20 = any;
|
|
2800
|
-
//#endregion
|
|
2801
2798
|
//#region src/plugins/@angular/common/types.d.ts
|
|
2802
|
-
type UserConfig$
|
|
2799
|
+
type UserConfig$23 = Plugin.Name<'@angular/common'> & Plugin.Hooks & {
|
|
2803
2800
|
/**
|
|
2804
2801
|
* Should the exports from the generated files be re-exported in the index
|
|
2805
2802
|
* barrel file?
|
|
@@ -2867,7 +2864,7 @@ type UserConfig$22 = Plugin.Name<'@angular/common'> & Plugin.Hooks & {
|
|
|
2867
2864
|
methodNameBuilder?: (operation: IR.OperationObject) => string;
|
|
2868
2865
|
};
|
|
2869
2866
|
};
|
|
2870
|
-
type Config$
|
|
2867
|
+
type Config$14 = Plugin.Name<'@angular/common'> & Plugin.Hooks & {
|
|
2871
2868
|
/**
|
|
2872
2869
|
* Should the exports from the generated files be re-exported in the index
|
|
2873
2870
|
* barrel file?
|
|
@@ -2930,13 +2927,10 @@ type Config$13 = Plugin.Name<'@angular/common'> & Plugin.Hooks & {
|
|
|
2930
2927
|
methodNameBuilder: (operation: IR.OperationObject) => string;
|
|
2931
2928
|
};
|
|
2932
2929
|
};
|
|
2933
|
-
type AngularCommonPlugin = DefinePlugin<UserConfig$
|
|
2934
|
-
//#endregion
|
|
2935
|
-
//#region src/plugins/@hey-api/client-axios/api.d.ts
|
|
2936
|
-
type IApi$19 = any;
|
|
2930
|
+
type AngularCommonPlugin = DefinePlugin<UserConfig$23, Config$14>;
|
|
2937
2931
|
//#endregion
|
|
2938
2932
|
//#region src/plugins/@hey-api/client-axios/types.d.ts
|
|
2939
|
-
type UserConfig$
|
|
2933
|
+
type UserConfig$22 = Plugin.Name<'@hey-api/client-axios'> & Client.Config & {
|
|
2940
2934
|
/**
|
|
2941
2935
|
* Throw an error instead of returning it in the response?
|
|
2942
2936
|
*
|
|
@@ -2944,13 +2938,10 @@ type UserConfig$21 = Plugin.Name<'@hey-api/client-axios'> & Client.Config & {
|
|
|
2944
2938
|
*/
|
|
2945
2939
|
throwOnError?: boolean;
|
|
2946
2940
|
};
|
|
2947
|
-
type HeyApiClientAxiosPlugin = DefinePlugin<UserConfig$
|
|
2948
|
-
//#endregion
|
|
2949
|
-
//#region src/plugins/@hey-api/client-fetch/api.d.ts
|
|
2950
|
-
type IApi$18 = any;
|
|
2941
|
+
type HeyApiClientAxiosPlugin = DefinePlugin<UserConfig$22, UserConfig$22>;
|
|
2951
2942
|
//#endregion
|
|
2952
2943
|
//#region src/plugins/@hey-api/client-fetch/types.d.ts
|
|
2953
|
-
type UserConfig$
|
|
2944
|
+
type UserConfig$21 = Plugin.Name<'@hey-api/client-fetch'> & Client.Config & {
|
|
2954
2945
|
/**
|
|
2955
2946
|
* Throw an error instead of returning it in the response?
|
|
2956
2947
|
*
|
|
@@ -2958,13 +2949,10 @@ type UserConfig$20 = Plugin.Name<'@hey-api/client-fetch'> & Client.Config & {
|
|
|
2958
2949
|
*/
|
|
2959
2950
|
throwOnError?: boolean;
|
|
2960
2951
|
};
|
|
2961
|
-
type HeyApiClientFetchPlugin = DefinePlugin<UserConfig$
|
|
2962
|
-
//#endregion
|
|
2963
|
-
//#region src/plugins/@hey-api/client-next/api.d.ts
|
|
2964
|
-
type IApi$17 = any;
|
|
2952
|
+
type HeyApiClientFetchPlugin = DefinePlugin<UserConfig$21, UserConfig$21>;
|
|
2965
2953
|
//#endregion
|
|
2966
2954
|
//#region src/plugins/@hey-api/client-next/types.d.ts
|
|
2967
|
-
type UserConfig$
|
|
2955
|
+
type UserConfig$20 = Plugin.Name<'@hey-api/client-next'> & Client.Config & {
|
|
2968
2956
|
/**
|
|
2969
2957
|
* Throw an error instead of returning it in the response?
|
|
2970
2958
|
*
|
|
@@ -2972,20 +2960,14 @@ type UserConfig$19 = Plugin.Name<'@hey-api/client-next'> & Client.Config & {
|
|
|
2972
2960
|
*/
|
|
2973
2961
|
throwOnError?: boolean;
|
|
2974
2962
|
};
|
|
2975
|
-
type HeyApiClientNextPlugin = DefinePlugin<UserConfig$
|
|
2976
|
-
//#endregion
|
|
2977
|
-
//#region src/plugins/@hey-api/client-nuxt/api.d.ts
|
|
2978
|
-
type IApi$16 = any;
|
|
2963
|
+
type HeyApiClientNextPlugin = DefinePlugin<UserConfig$20, UserConfig$20>;
|
|
2979
2964
|
//#endregion
|
|
2980
2965
|
//#region src/plugins/@hey-api/client-nuxt/types.d.ts
|
|
2981
|
-
type UserConfig$
|
|
2982
|
-
type HeyApiClientNuxtPlugin = DefinePlugin<UserConfig$
|
|
2983
|
-
//#endregion
|
|
2984
|
-
//#region src/plugins/@hey-api/client-ofetch/api.d.ts
|
|
2985
|
-
type IApi$15 = any;
|
|
2966
|
+
type UserConfig$19 = Plugin.Name<'@hey-api/client-nuxt'> & Client.Config;
|
|
2967
|
+
type HeyApiClientNuxtPlugin = DefinePlugin<UserConfig$19, UserConfig$19>;
|
|
2986
2968
|
//#endregion
|
|
2987
2969
|
//#region src/plugins/@hey-api/client-ofetch/types.d.ts
|
|
2988
|
-
type UserConfig$
|
|
2970
|
+
type UserConfig$18 = Plugin.Name<'@hey-api/client-ofetch'> & Client.Config & {
|
|
2989
2971
|
/**
|
|
2990
2972
|
* Throw an error instead of returning it in the response?
|
|
2991
2973
|
*
|
|
@@ -2993,7 +2975,7 @@ type UserConfig$17 = Plugin.Name<'@hey-api/client-ofetch'> & Client.Config & {
|
|
|
2993
2975
|
*/
|
|
2994
2976
|
throwOnError?: boolean;
|
|
2995
2977
|
};
|
|
2996
|
-
type HeyApiClientOfetchPlugin = DefinePlugin<UserConfig$
|
|
2978
|
+
type HeyApiClientOfetchPlugin = DefinePlugin<UserConfig$18, UserConfig$18>;
|
|
2997
2979
|
//#endregion
|
|
2998
2980
|
//#region src/plugins/@hey-api/client-core/types.d.ts
|
|
2999
2981
|
interface PluginHandler {
|
|
@@ -3062,11 +3044,19 @@ declare namespace Client {
|
|
|
3062
3044
|
};
|
|
3063
3045
|
}
|
|
3064
3046
|
//#endregion
|
|
3065
|
-
//#region src/plugins/@hey-api/client-angular/api.d.ts
|
|
3066
|
-
type IApi$14 = any;
|
|
3067
|
-
//#endregion
|
|
3068
3047
|
//#region src/plugins/@hey-api/client-angular/types.d.ts
|
|
3069
|
-
type UserConfig$
|
|
3048
|
+
type UserConfig$17 = Plugin.Name<'@hey-api/client-angular'> & Client.Config & {
|
|
3049
|
+
/**
|
|
3050
|
+
* Throw an error instead of returning it in the response?
|
|
3051
|
+
*
|
|
3052
|
+
* @default false
|
|
3053
|
+
*/
|
|
3054
|
+
throwOnError?: boolean;
|
|
3055
|
+
};
|
|
3056
|
+
type HeyApiClientAngularPlugin = DefinePlugin<UserConfig$17, UserConfig$17>;
|
|
3057
|
+
//#endregion
|
|
3058
|
+
//#region src/plugins/@hey-api/client-ky/types.d.ts
|
|
3059
|
+
type UserConfig$16 = Plugin.Name<'@hey-api/client-ky'> & Client.Config & {
|
|
3070
3060
|
/**
|
|
3071
3061
|
* Throw an error instead of returning it in the response?
|
|
3072
3062
|
*
|
|
@@ -3074,7 +3064,7 @@ type UserConfig$16 = Plugin.Name<'@hey-api/client-angular'> & Client.Config & {
|
|
|
3074
3064
|
*/
|
|
3075
3065
|
throwOnError?: boolean;
|
|
3076
3066
|
};
|
|
3077
|
-
type
|
|
3067
|
+
type HeyApiClientKyPlugin = DefinePlugin<UserConfig$16, UserConfig$16>;
|
|
3078
3068
|
//#endregion
|
|
3079
3069
|
//#region src/openApi/2.0.x/types/json-schema-draft-4.d.ts
|
|
3080
3070
|
interface JsonSchemaDraft4 extends EnumExtensions {
|
|
@@ -6024,9 +6014,6 @@ interface OpenApiV3_1_XTypes {
|
|
|
6024
6014
|
SchemaObject: SchemaObject;
|
|
6025
6015
|
}
|
|
6026
6016
|
//#endregion
|
|
6027
|
-
//#region src/plugins/@hey-api/schemas/api.d.ts
|
|
6028
|
-
type IApi$13 = any;
|
|
6029
|
-
//#endregion
|
|
6030
6017
|
//#region src/plugins/@hey-api/schemas/types.d.ts
|
|
6031
6018
|
type UserConfig$15 = Plugin.Name<'@hey-api/schemas'> & Plugin.Hooks & {
|
|
6032
6019
|
/**
|
|
@@ -6053,10 +6040,7 @@ type UserConfig$15 = Plugin.Name<'@hey-api/schemas'> & Plugin.Hooks & {
|
|
|
6053
6040
|
*/
|
|
6054
6041
|
type?: 'form' | 'json';
|
|
6055
6042
|
};
|
|
6056
|
-
type HeyApiSchemasPlugin = DefinePlugin<UserConfig$15, UserConfig$15
|
|
6057
|
-
//#endregion
|
|
6058
|
-
//#region src/plugins/@hey-api/sdk/api.d.ts
|
|
6059
|
-
type IApi$12 = any;
|
|
6043
|
+
type HeyApiSchemasPlugin = DefinePlugin<UserConfig$15, UserConfig$15>;
|
|
6060
6044
|
//#endregion
|
|
6061
6045
|
//#region src/plugins/@hey-api/sdk/types.d.ts
|
|
6062
6046
|
type UserConfig$14 = Plugin.Name<'@hey-api/sdk'> & Plugin.Hooks & {
|
|
@@ -6233,7 +6217,7 @@ type UserConfig$14 = Plugin.Name<'@hey-api/sdk'> & Plugin.Hooks & {
|
|
|
6233
6217
|
*/
|
|
6234
6218
|
response?: 'body' | 'response';
|
|
6235
6219
|
};
|
|
6236
|
-
type Config$
|
|
6220
|
+
type Config$13 = Plugin.Name<'@hey-api/sdk'> & Plugin.Hooks & {
|
|
6237
6221
|
/**
|
|
6238
6222
|
* Group operation methods into classes? When enabled, you can select which
|
|
6239
6223
|
* classes to export with `sdk.include` and/or transform their names with
|
|
@@ -6389,10 +6373,7 @@ type Config$12 = Plugin.Name<'@hey-api/sdk'> & Plugin.Hooks & {
|
|
|
6389
6373
|
*/
|
|
6390
6374
|
response: 'body' | 'response';
|
|
6391
6375
|
};
|
|
6392
|
-
type HeyApiSdkPlugin = DefinePlugin<UserConfig$14, Config$
|
|
6393
|
-
//#endregion
|
|
6394
|
-
//#region src/plugins/@hey-api/transformers/api.d.ts
|
|
6395
|
-
type IApi$11 = any;
|
|
6376
|
+
type HeyApiSdkPlugin = DefinePlugin<UserConfig$14, Config$13>;
|
|
6396
6377
|
//#endregion
|
|
6397
6378
|
//#region src/plugins/@hey-api/transformers/expressions.d.ts
|
|
6398
6379
|
type ExpressionTransformer = ({
|
|
@@ -6444,7 +6425,7 @@ type UserConfig$13 = Plugin.Name<'@hey-api/transformers'> & Plugin.Hooks & {
|
|
|
6444
6425
|
*/
|
|
6445
6426
|
typeTransformers?: ReadonlyArray<TypeTransformer>;
|
|
6446
6427
|
};
|
|
6447
|
-
type Config$
|
|
6428
|
+
type Config$12 = Plugin.Name<'@hey-api/transformers'> & Plugin.Hooks & {
|
|
6448
6429
|
/**
|
|
6449
6430
|
* Convert long integers into BigInt values?
|
|
6450
6431
|
*
|
|
@@ -6473,7 +6454,7 @@ type Config$11 = Plugin.Name<'@hey-api/transformers'> & Plugin.Hooks & {
|
|
|
6473
6454
|
*/
|
|
6474
6455
|
typeTransformers: ReadonlyArray<TypeTransformer>;
|
|
6475
6456
|
};
|
|
6476
|
-
type HeyApiTransformersPlugin = DefinePlugin<UserConfig$13, Config$
|
|
6457
|
+
type HeyApiTransformersPlugin = DefinePlugin<UserConfig$13, Config$12>;
|
|
6477
6458
|
//#endregion
|
|
6478
6459
|
//#region src/plugins/@hey-api/typescript/shared/types.d.ts
|
|
6479
6460
|
type IrSchemaToAstOptions = {
|
|
@@ -6492,7 +6473,7 @@ declare const irSchemaToAst: ({
|
|
|
6492
6473
|
}) => ts.TypeNode;
|
|
6493
6474
|
//#endregion
|
|
6494
6475
|
//#region src/plugins/@hey-api/typescript/api.d.ts
|
|
6495
|
-
type IApi$
|
|
6476
|
+
type IApi$3 = {
|
|
6496
6477
|
schemaToType: (args: Parameters<typeof irSchemaToAst>[0]) => ts.TypeNode;
|
|
6497
6478
|
};
|
|
6498
6479
|
//#endregion
|
|
@@ -6719,39 +6700,8 @@ type UserConfig$12 = Plugin.Name<'@hey-api/typescript'> & Plugin.Hooks & {
|
|
|
6719
6700
|
*/
|
|
6720
6701
|
payload?: StringName;
|
|
6721
6702
|
};
|
|
6722
|
-
|
|
6723
|
-
// DEPRECATED OPTIONS BELOW
|
|
6724
|
-
|
|
6725
|
-
/**
|
|
6726
|
-
* **This feature works only with the legacy parser**
|
|
6727
|
-
*
|
|
6728
|
-
* Include only types matching regular expression.
|
|
6729
|
-
*
|
|
6730
|
-
* @deprecated
|
|
6731
|
-
*/
|
|
6732
|
-
// eslint-disable-next-line typescript-sort-keys/interface
|
|
6733
|
-
include?: string;
|
|
6734
|
-
/**
|
|
6735
|
-
* **This feature works only with the legacy parser**
|
|
6736
|
-
*
|
|
6737
|
-
* Use your preferred naming pattern
|
|
6738
|
-
*
|
|
6739
|
-
* @deprecated
|
|
6740
|
-
* @default 'preserve'
|
|
6741
|
-
*/
|
|
6742
|
-
style?: 'PascalCase' | 'preserve';
|
|
6743
|
-
/**
|
|
6744
|
-
* **This feature works only with the legacy parser**
|
|
6745
|
-
*
|
|
6746
|
-
* Generate a tree of types containing all operations? It will be named
|
|
6747
|
-
* $OpenApiTs.
|
|
6748
|
-
*
|
|
6749
|
-
* @deprecated
|
|
6750
|
-
* @default false
|
|
6751
|
-
*/
|
|
6752
|
-
tree?: boolean;
|
|
6753
6703
|
};
|
|
6754
|
-
type Config$
|
|
6704
|
+
type Config$11 = Plugin.Name<'@hey-api/typescript'> & Plugin.Hooks & {
|
|
6755
6705
|
/**
|
|
6756
6706
|
* The casing convention to use for generated names.
|
|
6757
6707
|
*
|
|
@@ -6940,42 +6890,8 @@ type Config$10 = Plugin.Name<'@hey-api/typescript'> & Plugin.Hooks & {
|
|
|
6940
6890
|
*/
|
|
6941
6891
|
payload: StringName;
|
|
6942
6892
|
};
|
|
6943
|
-
|
|
6944
|
-
// DEPRECATED OPTIONS BELOW
|
|
6945
|
-
|
|
6946
|
-
/**
|
|
6947
|
-
* **This feature works only with the legacy parser**
|
|
6948
|
-
*
|
|
6949
|
-
* Include only types matching regular expression.
|
|
6950
|
-
*
|
|
6951
|
-
* @deprecated
|
|
6952
|
-
*/
|
|
6953
|
-
// eslint-disable-next-line typescript-sort-keys/interface
|
|
6954
|
-
include?: string;
|
|
6955
|
-
/**
|
|
6956
|
-
* **This feature works only with the legacy parser**
|
|
6957
|
-
*
|
|
6958
|
-
* Use your preferred naming pattern
|
|
6959
|
-
*
|
|
6960
|
-
* @deprecated
|
|
6961
|
-
* @default 'preserve'
|
|
6962
|
-
*/
|
|
6963
|
-
style: 'PascalCase' | 'preserve';
|
|
6964
|
-
/**
|
|
6965
|
-
* **This feature works only with the legacy parser**
|
|
6966
|
-
*
|
|
6967
|
-
* Generate a tree of types containing all operations? It will be named
|
|
6968
|
-
* $OpenApiTs.
|
|
6969
|
-
*
|
|
6970
|
-
* @deprecated
|
|
6971
|
-
* @default false
|
|
6972
|
-
*/
|
|
6973
|
-
tree: boolean;
|
|
6974
6893
|
};
|
|
6975
|
-
type HeyApiTypeScriptPlugin = DefinePlugin<UserConfig$12, Config$
|
|
6976
|
-
//#endregion
|
|
6977
|
-
//#region src/plugins/@pinia/colada/api.d.ts
|
|
6978
|
-
type IApi$9 = any;
|
|
6894
|
+
type HeyApiTypeScriptPlugin = DefinePlugin<UserConfig$12, Config$11, IApi$3>;
|
|
6979
6895
|
//#endregion
|
|
6980
6896
|
//#region src/plugins/@pinia/colada/types.d.ts
|
|
6981
6897
|
type UserConfig$11 = Plugin.Name<'@pinia/colada'> & Plugin.Hooks & {
|
|
@@ -7156,7 +7072,7 @@ type UserConfig$11 = Plugin.Name<'@pinia/colada'> & Plugin.Hooks & {
|
|
|
7156
7072
|
name?: StringName;
|
|
7157
7073
|
};
|
|
7158
7074
|
};
|
|
7159
|
-
type Config$
|
|
7075
|
+
type Config$10 = Plugin.Name<'@pinia/colada'> & Plugin.Hooks & {
|
|
7160
7076
|
/**
|
|
7161
7077
|
* The casing convention to use for generated names.
|
|
7162
7078
|
*
|
|
@@ -7305,10 +7221,7 @@ type Config$9 = Plugin.Name<'@pinia/colada'> & Plugin.Hooks & {
|
|
|
7305
7221
|
name: StringName;
|
|
7306
7222
|
};
|
|
7307
7223
|
};
|
|
7308
|
-
type PiniaColadaPlugin = DefinePlugin<UserConfig$11, Config$
|
|
7309
|
-
//#endregion
|
|
7310
|
-
//#region src/plugins/@tanstack/angular-query-experimental/api.d.ts
|
|
7311
|
-
type IApi$8 = any;
|
|
7224
|
+
type PiniaColadaPlugin = DefinePlugin<UserConfig$11, Config$10>;
|
|
7312
7225
|
//#endregion
|
|
7313
7226
|
//#region src/plugins/@tanstack/angular-query-experimental/types.d.ts
|
|
7314
7227
|
type UserConfig$10 = Plugin.Name<'@tanstack/angular-query-experimental'> & Plugin.Hooks & {
|
|
@@ -7592,7 +7505,7 @@ type UserConfig$10 = Plugin.Name<'@tanstack/angular-query-experimental'> & Plugi
|
|
|
7592
7505
|
name?: StringName;
|
|
7593
7506
|
};
|
|
7594
7507
|
};
|
|
7595
|
-
type Config$
|
|
7508
|
+
type Config$9 = Plugin.Name<'@tanstack/angular-query-experimental'> & Plugin.Hooks & {
|
|
7596
7509
|
/**
|
|
7597
7510
|
* The casing convention to use for generated names.
|
|
7598
7511
|
*
|
|
@@ -7833,10 +7746,7 @@ type Config$8 = Plugin.Name<'@tanstack/angular-query-experimental'> & Plugin.Hoo
|
|
|
7833
7746
|
name: StringName;
|
|
7834
7747
|
};
|
|
7835
7748
|
};
|
|
7836
|
-
type TanStackAngularQueryPlugin = DefinePlugin<UserConfig$10, Config$
|
|
7837
|
-
//#endregion
|
|
7838
|
-
//#region src/plugins/@tanstack/react-query/api.d.ts
|
|
7839
|
-
type IApi$7 = any;
|
|
7749
|
+
type TanStackAngularQueryPlugin = DefinePlugin<UserConfig$10, Config$9>;
|
|
7840
7750
|
//#endregion
|
|
7841
7751
|
//#region src/plugins/@tanstack/react-query/types.d.ts
|
|
7842
7752
|
type UserConfig$9 = Plugin.Name<'@tanstack/react-query'> & Plugin.Hooks & {
|
|
@@ -8164,7 +8074,7 @@ type UserConfig$9 = Plugin.Name<'@tanstack/react-query'> & Plugin.Hooks & {
|
|
|
8164
8074
|
name?: StringName;
|
|
8165
8075
|
};
|
|
8166
8076
|
};
|
|
8167
|
-
type Config$
|
|
8077
|
+
type Config$8 = Plugin.Name<'@tanstack/react-query'> & Plugin.Hooks & {
|
|
8168
8078
|
/**
|
|
8169
8079
|
* The casing convention to use for generated names.
|
|
8170
8080
|
*
|
|
@@ -8436,10 +8346,7 @@ type Config$7 = Plugin.Name<'@tanstack/react-query'> & Plugin.Hooks & {
|
|
|
8436
8346
|
name: StringName;
|
|
8437
8347
|
};
|
|
8438
8348
|
};
|
|
8439
|
-
type TanStackReactQueryPlugin = DefinePlugin<UserConfig$9, Config$
|
|
8440
|
-
//#endregion
|
|
8441
|
-
//#region src/plugins/@tanstack/solid-query/api.d.ts
|
|
8442
|
-
type IApi$6 = any;
|
|
8349
|
+
type TanStackReactQueryPlugin = DefinePlugin<UserConfig$9, Config$8>;
|
|
8443
8350
|
//#endregion
|
|
8444
8351
|
//#region src/plugins/@tanstack/solid-query/types.d.ts
|
|
8445
8352
|
type UserConfig$8 = Plugin.Name<'@tanstack/solid-query'> & Plugin.Hooks & {
|
|
@@ -8724,7 +8631,7 @@ type UserConfig$8 = Plugin.Name<'@tanstack/solid-query'> & Plugin.Hooks & {
|
|
|
8724
8631
|
name?: StringName;
|
|
8725
8632
|
};
|
|
8726
8633
|
};
|
|
8727
|
-
type Config$
|
|
8634
|
+
type Config$7 = Plugin.Name<'@tanstack/solid-query'> & Plugin.Hooks & {
|
|
8728
8635
|
/**
|
|
8729
8636
|
* The casing convention to use for generated names.
|
|
8730
8637
|
*
|
|
@@ -8965,10 +8872,7 @@ type Config$6 = Plugin.Name<'@tanstack/solid-query'> & Plugin.Hooks & {
|
|
|
8965
8872
|
name: StringName;
|
|
8966
8873
|
};
|
|
8967
8874
|
};
|
|
8968
|
-
type TanStackSolidQueryPlugin = DefinePlugin<UserConfig$8, Config$
|
|
8969
|
-
//#endregion
|
|
8970
|
-
//#region src/plugins/@tanstack/svelte-query/api.d.ts
|
|
8971
|
-
type IApi$5 = any;
|
|
8875
|
+
type TanStackSolidQueryPlugin = DefinePlugin<UserConfig$8, Config$7>;
|
|
8972
8876
|
//#endregion
|
|
8973
8877
|
//#region src/plugins/@tanstack/svelte-query/types.d.ts
|
|
8974
8878
|
type UserConfig$7 = Plugin.Name<'@tanstack/svelte-query'> & Plugin.Hooks & {
|
|
@@ -9252,7 +9156,7 @@ type UserConfig$7 = Plugin.Name<'@tanstack/svelte-query'> & Plugin.Hooks & {
|
|
|
9252
9156
|
name?: StringName;
|
|
9253
9157
|
};
|
|
9254
9158
|
};
|
|
9255
|
-
type Config$
|
|
9159
|
+
type Config$6 = Plugin.Name<'@tanstack/svelte-query'> & Plugin.Hooks & {
|
|
9256
9160
|
/**
|
|
9257
9161
|
* The casing convention to use for generated names.
|
|
9258
9162
|
*
|
|
@@ -9493,10 +9397,7 @@ type Config$5 = Plugin.Name<'@tanstack/svelte-query'> & Plugin.Hooks & {
|
|
|
9493
9397
|
name: StringName;
|
|
9494
9398
|
};
|
|
9495
9399
|
};
|
|
9496
|
-
type TanStackSvelteQueryPlugin = DefinePlugin<UserConfig$7, Config$
|
|
9497
|
-
//#endregion
|
|
9498
|
-
//#region src/plugins/@tanstack/vue-query/api.d.ts
|
|
9499
|
-
type IApi$4 = any;
|
|
9400
|
+
type TanStackSvelteQueryPlugin = DefinePlugin<UserConfig$7, Config$6>;
|
|
9500
9401
|
//#endregion
|
|
9501
9402
|
//#region src/plugins/@tanstack/vue-query/types.d.ts
|
|
9502
9403
|
type UserConfig$6 = Plugin.Name<'@tanstack/vue-query'> & Plugin.Hooks & {
|
|
@@ -9783,7 +9684,7 @@ type UserConfig$6 = Plugin.Name<'@tanstack/vue-query'> & Plugin.Hooks & {
|
|
|
9783
9684
|
name?: StringName;
|
|
9784
9685
|
};
|
|
9785
9686
|
};
|
|
9786
|
-
type Config$
|
|
9687
|
+
type Config$5 = Plugin.Name<'@tanstack/vue-query'> & Plugin.Hooks & {
|
|
9787
9688
|
/**
|
|
9788
9689
|
* The casing convention to use for generated names.
|
|
9789
9690
|
*
|
|
@@ -10027,7 +9928,32 @@ type Config$4 = Plugin.Name<'@tanstack/vue-query'> & Plugin.Hooks & {
|
|
|
10027
9928
|
name: StringName;
|
|
10028
9929
|
};
|
|
10029
9930
|
};
|
|
10030
|
-
type TanStackVueQueryPlugin = DefinePlugin<UserConfig$6, Config$
|
|
9931
|
+
type TanStackVueQueryPlugin = DefinePlugin<UserConfig$6, Config$5>;
|
|
9932
|
+
//#endregion
|
|
9933
|
+
//#region src/ts-dsl/base.d.ts
|
|
9934
|
+
type MaybeArray$1<T> = T | ReadonlyArray<T>;
|
|
9935
|
+
type WithStatement<T = ts.Expression> = T | ts.Statement;
|
|
9936
|
+
type WithString<T = ts.Expression> = T | string;
|
|
9937
|
+
interface ITsDsl<T extends ts.Node = ts.Node> {
|
|
9938
|
+
$render(): T;
|
|
9939
|
+
}
|
|
9940
|
+
declare abstract class TsDsl<T extends ts.Node = ts.Node> implements ITsDsl<T> {
|
|
9941
|
+
abstract $render(): T;
|
|
9942
|
+
protected $expr<T>(expr: WithString<T>): T;
|
|
9943
|
+
/** Conditionally applies a callback to this builder. */
|
|
9944
|
+
$if<T extends TsDsl, V$1, R extends TsDsl = T>(this: T, value: V$1, ifTrue: (self: T, v: Exclude<V$1, false | null | undefined>) => R | void, ifFalse?: (self: T, v: Extract<V$1, false | null | undefined>) => R | void): R | T;
|
|
9945
|
+
$if<T extends TsDsl, V$1, R extends TsDsl = T>(this: T, value: V$1, ifTrue: (v: Exclude<V$1, false | null | undefined>) => R | void, ifFalse?: (v: Extract<V$1, false | null | undefined>) => R | void): R | T;
|
|
9946
|
+
$if<T extends TsDsl, V$1, R extends TsDsl = T>(this: T, value: V$1, ifTrue: () => R | void, ifFalse?: () => R | void): R | T;
|
|
9947
|
+
protected $node<I>(input: I): NodeOfMaybe<I>;
|
|
9948
|
+
protected $stmt(input: MaybeArray$1<MaybeTsDsl<WithString<WithStatement>>>): ReadonlyArray<ts.Statement>;
|
|
9949
|
+
protected $type<I>(input: I, args?: ReadonlyArray<ts.TypeNode>): TypeOfMaybe<I>;
|
|
9950
|
+
private _render;
|
|
9951
|
+
}
|
|
9952
|
+
type NodeOfMaybe<I> = undefined extends I ? NodeOf<NonNullable<I>> | undefined : NodeOf<I>;
|
|
9953
|
+
type NodeOf<I> = I extends ReadonlyArray<infer U> ? ReadonlyArray<U extends TsDsl<infer N> ? N : U> : I extends string ? ts.Expression : I extends boolean ? ts.Expression : I extends TsDsl<infer N> ? N : I extends ts.Node ? I : never;
|
|
9954
|
+
type MaybeTsDsl<T> = string extends T ? Exclude<T, string> extends ts.Node ? string | Exclude<T, string> | TsDsl<Exclude<T, string>> : string : T extends TsDsl<any> ? T : T extends ts.Node ? T | TsDsl<T> : never;
|
|
9955
|
+
type TypeOfMaybe<I> = undefined extends I ? TypeOf<NonNullable<I>> | undefined : TypeOf<I>;
|
|
9956
|
+
type TypeOf<I> = I extends ReadonlyArray<infer U> ? ReadonlyArray<TypeOf<U>> : I extends string ? ts.TypeNode : I extends boolean ? ts.LiteralTypeNode : I extends TsDsl<infer N> ? N : I extends ts.TypeNode ? I : never;
|
|
10031
9957
|
//#endregion
|
|
10032
9958
|
//#region src/plugins/arktype/shared/types.d.ts
|
|
10033
9959
|
type ValidatorArgs$2 = {
|
|
@@ -10036,9 +9962,9 @@ type ValidatorArgs$2 = {
|
|
|
10036
9962
|
};
|
|
10037
9963
|
//#endregion
|
|
10038
9964
|
//#region src/plugins/arktype/api.d.ts
|
|
10039
|
-
type IApi$
|
|
10040
|
-
createRequestValidator: (args: ValidatorArgs$2) =>
|
|
10041
|
-
createResponseValidator: (args: ValidatorArgs$2) =>
|
|
9965
|
+
type IApi$2 = {
|
|
9966
|
+
createRequestValidator: (args: ValidatorArgs$2) => TsDsl | undefined;
|
|
9967
|
+
createResponseValidator: (args: ValidatorArgs$2) => TsDsl | undefined;
|
|
10042
9968
|
};
|
|
10043
9969
|
//#endregion
|
|
10044
9970
|
//#region src/plugins/arktype/types.d.ts
|
|
@@ -10387,7 +10313,7 @@ type UserConfig$5 = Plugin.Name<'arktype'> & Plugin.Hooks & {
|
|
|
10387
10313
|
};
|
|
10388
10314
|
};
|
|
10389
10315
|
};
|
|
10390
|
-
type Config$
|
|
10316
|
+
type Config$4 = Plugin.Name<'arktype'> & Plugin.Hooks & {
|
|
10391
10317
|
/**
|
|
10392
10318
|
* The casing convention to use for generated names.
|
|
10393
10319
|
*
|
|
@@ -10671,10 +10597,7 @@ type Config$3 = Plugin.Name<'arktype'> & Plugin.Hooks & {
|
|
|
10671
10597
|
};
|
|
10672
10598
|
};
|
|
10673
10599
|
};
|
|
10674
|
-
type ArktypePlugin = DefinePlugin<UserConfig$5, Config$
|
|
10675
|
-
//#endregion
|
|
10676
|
-
//#region src/plugins/fastify/api.d.ts
|
|
10677
|
-
type IApi$2 = any;
|
|
10600
|
+
type ArktypePlugin = DefinePlugin<UserConfig$5, Config$4, IApi$2>;
|
|
10678
10601
|
//#endregion
|
|
10679
10602
|
//#region src/plugins/fastify/types.d.ts
|
|
10680
10603
|
type UserConfig$4 = Plugin.Name<'fastify'> & Plugin.Hooks & {
|
|
@@ -10686,22 +10609,10 @@ type UserConfig$4 = Plugin.Name<'fastify'> & Plugin.Hooks & {
|
|
|
10686
10609
|
*/
|
|
10687
10610
|
exportFromIndex?: boolean;
|
|
10688
10611
|
};
|
|
10689
|
-
type FastifyPlugin = DefinePlugin<UserConfig$4, UserConfig$4
|
|
10690
|
-
//#endregion
|
|
10691
|
-
//#region src/plugins/valibot/shared/types.d.ts
|
|
10692
|
-
type ValidatorArgs$1 = {
|
|
10693
|
-
operation: IR$1.OperationObject;
|
|
10694
|
-
plugin: ValibotPlugin['Instance'];
|
|
10695
|
-
};
|
|
10696
|
-
//#endregion
|
|
10697
|
-
//#region src/plugins/valibot/api.d.ts
|
|
10698
|
-
type IApi$1 = {
|
|
10699
|
-
createRequestValidator: (args: ValidatorArgs$1) => ts.ArrowFunction | undefined;
|
|
10700
|
-
createResponseValidator: (args: ValidatorArgs$1) => ts.ArrowFunction | undefined;
|
|
10701
|
-
};
|
|
10612
|
+
type FastifyPlugin = DefinePlugin<UserConfig$4, UserConfig$4>;
|
|
10702
10613
|
//#endregion
|
|
10703
|
-
//#region src/plugins/
|
|
10704
|
-
type UserConfig$3 = Plugin.Name<'
|
|
10614
|
+
//#region src/plugins/swr/types.d.ts
|
|
10615
|
+
type UserConfig$3 = Plugin.Name<'swr'> & Plugin.Hooks & {
|
|
10705
10616
|
/**
|
|
10706
10617
|
* The casing convention to use for generated names.
|
|
10707
10618
|
*
|
|
@@ -10709,23 +10620,36 @@ type UserConfig$3 = Plugin.Name<'valibot'> & Plugin.Hooks & {
|
|
|
10709
10620
|
*/
|
|
10710
10621
|
case?: StringCase;
|
|
10711
10622
|
/**
|
|
10712
|
-
* Add comments from
|
|
10623
|
+
* Add comments from SDK functions to the generated SWR code?
|
|
10624
|
+
*
|
|
10625
|
+
* Duplicating comments this way is useful so you don't need to drill into
|
|
10626
|
+
* the underlying SDK function to learn what it does or whether it's
|
|
10627
|
+
* deprecated. You can set this option to `false` if you prefer less
|
|
10628
|
+
* comment duplication.
|
|
10713
10629
|
*
|
|
10714
10630
|
* @default true
|
|
10715
10631
|
*/
|
|
10716
10632
|
comments?: boolean;
|
|
10717
10633
|
/**
|
|
10718
|
-
*
|
|
10634
|
+
* Should the exports from the generated files be re-exported in the index
|
|
10635
|
+
* barrel file?
|
|
10719
10636
|
*
|
|
10720
|
-
*
|
|
10721
|
-
|
|
10637
|
+
* @default false
|
|
10638
|
+
*/
|
|
10639
|
+
exportFromIndex?: boolean;
|
|
10640
|
+
/**
|
|
10641
|
+
* Configuration for generated infinite query key helpers.
|
|
10642
|
+
*
|
|
10643
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/infiniteQueryOptions infiniteQueryOptions}
|
|
10722
10644
|
*
|
|
10723
10645
|
* Can be:
|
|
10724
10646
|
* - `boolean`: Shorthand for `{ enabled: boolean }`
|
|
10725
10647
|
* - `string` or `function`: Shorthand for `{ name: string | function }`
|
|
10726
10648
|
* - `object`: Full configuration object
|
|
10649
|
+
*
|
|
10650
|
+
* @default true
|
|
10727
10651
|
*/
|
|
10728
|
-
|
|
10652
|
+
infiniteQueryKeys?: boolean | StringName | {
|
|
10729
10653
|
/**
|
|
10730
10654
|
* The casing convention to use for generated names.
|
|
10731
10655
|
*
|
|
@@ -10733,46 +10657,41 @@ type UserConfig$3 = Plugin.Name<'valibot'> & Plugin.Hooks & {
|
|
|
10733
10657
|
*/
|
|
10734
10658
|
case?: StringCase;
|
|
10735
10659
|
/**
|
|
10736
|
-
* Whether to generate
|
|
10660
|
+
* Whether to generate infinite query key helpers.
|
|
10737
10661
|
*
|
|
10738
10662
|
* @default true
|
|
10739
10663
|
*/
|
|
10740
10664
|
enabled?: boolean;
|
|
10741
10665
|
/**
|
|
10742
|
-
* Custom naming pattern for generated
|
|
10743
|
-
*
|
|
10666
|
+
* Custom naming pattern for generated infinite query key names. The name variable is
|
|
10667
|
+
* obtained from the SDK function name.
|
|
10744
10668
|
*
|
|
10745
|
-
* @
|
|
10669
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/infiniteQueryOptions infiniteQueryOptions}
|
|
10670
|
+
*
|
|
10671
|
+
* @default '{{name}}InfiniteQueryKey'
|
|
10746
10672
|
*/
|
|
10747
10673
|
name?: StringName;
|
|
10674
|
+
/**
|
|
10675
|
+
* Whether to include operation tags in infinite query keys.
|
|
10676
|
+
* This will make query keys larger but provides better cache invalidation capabilities.
|
|
10677
|
+
*
|
|
10678
|
+
* @default false
|
|
10679
|
+
*/
|
|
10680
|
+
tags?: boolean;
|
|
10748
10681
|
};
|
|
10749
10682
|
/**
|
|
10750
|
-
*
|
|
10751
|
-
* barrel file?
|
|
10752
|
-
*
|
|
10753
|
-
* @default false
|
|
10754
|
-
*/
|
|
10755
|
-
exportFromIndex?: boolean;
|
|
10756
|
-
/**
|
|
10757
|
-
* Enable Valibot metadata support? It's often useful to associate a schema
|
|
10758
|
-
* with some additional metadata for documentation, code generation, AI
|
|
10759
|
-
* structured outputs, form validation, and other purposes.
|
|
10760
|
-
*
|
|
10761
|
-
* @default false
|
|
10762
|
-
*/
|
|
10763
|
-
metadata?: boolean;
|
|
10764
|
-
/**
|
|
10765
|
-
* Configuration for request-specific Valibot schemas.
|
|
10683
|
+
* Configuration for generated infinite query options helpers.
|
|
10766
10684
|
*
|
|
10767
|
-
*
|
|
10768
|
-
* parameters, path parameters, and headers.
|
|
10685
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/infiniteQueryOptions infiniteQueryOptions}
|
|
10769
10686
|
*
|
|
10770
10687
|
* Can be:
|
|
10771
10688
|
* - `boolean`: Shorthand for `{ enabled: boolean }`
|
|
10772
10689
|
* - `string` or `function`: Shorthand for `{ name: string | function }`
|
|
10773
10690
|
* - `object`: Full configuration object
|
|
10691
|
+
*
|
|
10692
|
+
* @default true
|
|
10774
10693
|
*/
|
|
10775
|
-
|
|
10694
|
+
infiniteQueryOptions?: boolean | StringName | {
|
|
10776
10695
|
/**
|
|
10777
10696
|
* The casing convention to use for generated names.
|
|
10778
10697
|
*
|
|
@@ -10780,31 +10699,57 @@ type UserConfig$3 = Plugin.Name<'valibot'> & Plugin.Hooks & {
|
|
|
10780
10699
|
*/
|
|
10781
10700
|
case?: StringCase;
|
|
10782
10701
|
/**
|
|
10783
|
-
* Whether to generate
|
|
10702
|
+
* Whether to generate infinite query options helpers.
|
|
10784
10703
|
*
|
|
10785
10704
|
* @default true
|
|
10786
10705
|
*/
|
|
10787
10706
|
enabled?: boolean;
|
|
10788
10707
|
/**
|
|
10789
|
-
* Custom
|
|
10790
|
-
*
|
|
10708
|
+
* Custom function to generate metadata for the operation.
|
|
10709
|
+
* Can return any valid meta object that will be included in the generated infinite query options.
|
|
10791
10710
|
*
|
|
10792
|
-
* @
|
|
10711
|
+
* @param operation - The operation object containing all available metadata
|
|
10712
|
+
* @returns A meta object with any properties you want to include
|
|
10713
|
+
*
|
|
10714
|
+
* @example
|
|
10715
|
+
* ```typescript
|
|
10716
|
+
* meta: (operation) => ({
|
|
10717
|
+
* customField: operation.id,
|
|
10718
|
+
* isDeprecated: operation.deprecated,
|
|
10719
|
+
* tags: operation.tags,
|
|
10720
|
+
* customObject: {
|
|
10721
|
+
* method: operation.method,
|
|
10722
|
+
* path: operation.path
|
|
10723
|
+
* }
|
|
10724
|
+
* })
|
|
10725
|
+
* ```
|
|
10726
|
+
*
|
|
10727
|
+
* @default undefined
|
|
10728
|
+
*/
|
|
10729
|
+
meta?: (operation: IR$1.OperationObject) => Record<string, unknown>;
|
|
10730
|
+
/**
|
|
10731
|
+
* Custom naming pattern for generated infinite query options names. The name variable is
|
|
10732
|
+
* obtained from the SDK function name.
|
|
10733
|
+
*
|
|
10734
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/infiniteQueryOptions infiniteQueryOptions}
|
|
10735
|
+
*
|
|
10736
|
+
* @default '{{name}}InfiniteOptions'
|
|
10793
10737
|
*/
|
|
10794
10738
|
name?: StringName;
|
|
10795
10739
|
};
|
|
10796
10740
|
/**
|
|
10797
|
-
* Configuration for
|
|
10741
|
+
* Configuration for generated mutation options helpers.
|
|
10798
10742
|
*
|
|
10799
|
-
*
|
|
10800
|
-
* responses, and status codes.
|
|
10743
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/useMutation useMutation}
|
|
10801
10744
|
*
|
|
10802
10745
|
* Can be:
|
|
10803
10746
|
* - `boolean`: Shorthand for `{ enabled: boolean }`
|
|
10804
10747
|
* - `string` or `function`: Shorthand for `{ name: string | function }`
|
|
10805
10748
|
* - `object`: Full configuration object
|
|
10749
|
+
*
|
|
10750
|
+
* @default true
|
|
10806
10751
|
*/
|
|
10807
|
-
|
|
10752
|
+
mutationOptions?: boolean | StringName | {
|
|
10808
10753
|
/**
|
|
10809
10754
|
* The casing convention to use for generated names.
|
|
10810
10755
|
*
|
|
@@ -10812,23 +10757,48 @@ type UserConfig$3 = Plugin.Name<'valibot'> & Plugin.Hooks & {
|
|
|
10812
10757
|
*/
|
|
10813
10758
|
case?: StringCase;
|
|
10814
10759
|
/**
|
|
10815
|
-
* Whether to generate
|
|
10760
|
+
* Whether to generate mutation options helpers.
|
|
10816
10761
|
*
|
|
10817
10762
|
* @default true
|
|
10818
10763
|
*/
|
|
10819
10764
|
enabled?: boolean;
|
|
10820
10765
|
/**
|
|
10821
|
-
* Custom
|
|
10822
|
-
*
|
|
10766
|
+
* Custom function to generate metadata for the operation.
|
|
10767
|
+
* Can return any valid meta object that will be included in the generated mutation options.
|
|
10823
10768
|
*
|
|
10824
|
-
* @
|
|
10769
|
+
* @param operation - The operation object containing all available metadata
|
|
10770
|
+
* @returns A meta object with any properties you want to include
|
|
10771
|
+
*
|
|
10772
|
+
* @example
|
|
10773
|
+
* ```typescript
|
|
10774
|
+
* meta: (operation) => ({
|
|
10775
|
+
* customField: operation.id,
|
|
10776
|
+
* isDeprecated: operation.deprecated,
|
|
10777
|
+
* tags: operation.tags,
|
|
10778
|
+
* customObject: {
|
|
10779
|
+
* method: operation.method,
|
|
10780
|
+
* path: operation.path
|
|
10781
|
+
* }
|
|
10782
|
+
* })
|
|
10783
|
+
* ```
|
|
10784
|
+
*
|
|
10785
|
+
* @default undefined
|
|
10786
|
+
*/
|
|
10787
|
+
meta?: (operation: IR$1.OperationObject) => Record<string, unknown>;
|
|
10788
|
+
/**
|
|
10789
|
+
* Custom naming pattern for generated mutation options names. The name variable is
|
|
10790
|
+
* obtained from the SDK function name.
|
|
10791
|
+
*
|
|
10792
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/useMutation useMutation}
|
|
10793
|
+
*
|
|
10794
|
+
* @default '{{name}}Mutation'
|
|
10825
10795
|
*/
|
|
10826
10796
|
name?: StringName;
|
|
10827
10797
|
};
|
|
10828
10798
|
/**
|
|
10829
|
-
* Configuration for
|
|
10799
|
+
* Configuration for generated query keys.
|
|
10830
10800
|
*
|
|
10831
|
-
*
|
|
10801
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/queryKey queryKey}
|
|
10832
10802
|
*
|
|
10833
10803
|
* Can be:
|
|
10834
10804
|
* - `boolean`: Shorthand for `{ enabled: boolean }`
|
|
@@ -10837,7 +10807,7 @@ type UserConfig$3 = Plugin.Name<'valibot'> & Plugin.Hooks & {
|
|
|
10837
10807
|
*
|
|
10838
10808
|
* @default true
|
|
10839
10809
|
*/
|
|
10840
|
-
|
|
10810
|
+
queryKeys?: boolean | StringName | {
|
|
10841
10811
|
/**
|
|
10842
10812
|
* The casing convention to use for generated names.
|
|
10843
10813
|
*
|
|
@@ -10845,26 +10815,579 @@ type UserConfig$3 = Plugin.Name<'valibot'> & Plugin.Hooks & {
|
|
|
10845
10815
|
*/
|
|
10846
10816
|
case?: StringCase;
|
|
10847
10817
|
/**
|
|
10848
|
-
* Whether to generate
|
|
10818
|
+
* Whether to generate query keys.
|
|
10849
10819
|
*
|
|
10850
10820
|
* @default true
|
|
10851
10821
|
*/
|
|
10852
10822
|
enabled?: boolean;
|
|
10853
10823
|
/**
|
|
10854
|
-
* Custom naming pattern for generated
|
|
10855
|
-
*
|
|
10824
|
+
* Custom naming pattern for generated query key names. The name variable is
|
|
10825
|
+
* obtained from the SDK function name.
|
|
10856
10826
|
*
|
|
10857
|
-
* @
|
|
10827
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/guides/query-keys Query Keys}
|
|
10828
|
+
*
|
|
10829
|
+
* @default '{{name}}QueryKey'
|
|
10858
10830
|
*/
|
|
10859
10831
|
name?: StringName;
|
|
10832
|
+
/**
|
|
10833
|
+
* Whether to include operation tags in query keys.
|
|
10834
|
+
* This will make query keys larger but provides better cache invalidation capabilities.
|
|
10835
|
+
*
|
|
10836
|
+
* @default false
|
|
10837
|
+
*/
|
|
10838
|
+
tags?: boolean;
|
|
10860
10839
|
};
|
|
10861
|
-
};
|
|
10862
|
-
type Config$2 = Plugin.Name<'valibot'> & Plugin.Hooks & {
|
|
10863
10840
|
/**
|
|
10864
|
-
*
|
|
10841
|
+
* Configuration for generated query options helpers.
|
|
10865
10842
|
*
|
|
10866
|
-
* @
|
|
10867
|
-
|
|
10843
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/queryOptions queryOptions}
|
|
10844
|
+
*
|
|
10845
|
+
* Can be:
|
|
10846
|
+
* - `boolean`: Shorthand for `{ enabled: boolean }`
|
|
10847
|
+
* - `string` or `function`: Shorthand for `{ name: string | function }`
|
|
10848
|
+
* - `object`: Full configuration object
|
|
10849
|
+
*
|
|
10850
|
+
* @default true
|
|
10851
|
+
*/
|
|
10852
|
+
queryOptions?: boolean | StringName | {
|
|
10853
|
+
/**
|
|
10854
|
+
* The casing convention to use for generated names.
|
|
10855
|
+
*
|
|
10856
|
+
* @default 'camelCase'
|
|
10857
|
+
*/
|
|
10858
|
+
case?: StringCase;
|
|
10859
|
+
/**
|
|
10860
|
+
* Whether to generate query options helpers.
|
|
10861
|
+
*
|
|
10862
|
+
* @default true
|
|
10863
|
+
*/
|
|
10864
|
+
enabled?: boolean;
|
|
10865
|
+
/**
|
|
10866
|
+
* Whether to export generated symbols.
|
|
10867
|
+
*
|
|
10868
|
+
* @default true
|
|
10869
|
+
*/
|
|
10870
|
+
exported?: boolean;
|
|
10871
|
+
/**
|
|
10872
|
+
* Custom function to generate metadata for the operation.
|
|
10873
|
+
* Can return any valid meta object that will be included in the generated query options.
|
|
10874
|
+
*
|
|
10875
|
+
* @param operation - The operation object containing all available metadata
|
|
10876
|
+
* @returns A meta object with any properties you want to include
|
|
10877
|
+
*
|
|
10878
|
+
* @example
|
|
10879
|
+
* ```typescript
|
|
10880
|
+
* meta: (operation) => ({
|
|
10881
|
+
* customField: operation.id,
|
|
10882
|
+
* isDeprecated: operation.deprecated,
|
|
10883
|
+
* tags: operation.tags,
|
|
10884
|
+
* customObject: {
|
|
10885
|
+
* method: operation.method,
|
|
10886
|
+
* path: operation.path
|
|
10887
|
+
* }
|
|
10888
|
+
* })
|
|
10889
|
+
* ```
|
|
10890
|
+
*
|
|
10891
|
+
* @default undefined
|
|
10892
|
+
*/
|
|
10893
|
+
meta?: (operation: IR$1.OperationObject) => Record<string, unknown>;
|
|
10894
|
+
/**
|
|
10895
|
+
* Custom naming pattern for generated query options names. The name variable is
|
|
10896
|
+
* obtained from the SDK function name.
|
|
10897
|
+
*
|
|
10898
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/queryOptions queryOptions}
|
|
10899
|
+
*
|
|
10900
|
+
* @default '{{name}}Options'
|
|
10901
|
+
*/
|
|
10902
|
+
name?: StringName;
|
|
10903
|
+
};
|
|
10904
|
+
/**
|
|
10905
|
+
* Configuration for generated `useSwr()` function helpers.
|
|
10906
|
+
*
|
|
10907
|
+
* See {@link https://swr.vercel.app/docs/api API}
|
|
10908
|
+
*
|
|
10909
|
+
* Can be:
|
|
10910
|
+
* - `boolean`: Shorthand for `{ enabled: boolean }`
|
|
10911
|
+
* - `string` or `function`: Shorthand for `{ name: string | function }`
|
|
10912
|
+
* - `object`: Full configuration object
|
|
10913
|
+
*
|
|
10914
|
+
* @default true
|
|
10915
|
+
*/
|
|
10916
|
+
useSwr?: boolean | StringName | {
|
|
10917
|
+
/**
|
|
10918
|
+
* The casing convention to use for generated names.
|
|
10919
|
+
*
|
|
10920
|
+
* @default 'camelCase'
|
|
10921
|
+
*/
|
|
10922
|
+
case?: StringCase;
|
|
10923
|
+
/**
|
|
10924
|
+
* Whether to generate `useSwr()` function helpers.
|
|
10925
|
+
*
|
|
10926
|
+
* @default true
|
|
10927
|
+
*/
|
|
10928
|
+
enabled?: boolean;
|
|
10929
|
+
/**
|
|
10930
|
+
* Custom naming pattern for generated `useSwr()` function names. The name variable is
|
|
10931
|
+
* obtained from the SDK function name.
|
|
10932
|
+
*
|
|
10933
|
+
* See {@link https://swr.vercel.app/docs/api API}
|
|
10934
|
+
*
|
|
10935
|
+
* @default 'use{{name}}'
|
|
10936
|
+
*/
|
|
10937
|
+
name?: StringName;
|
|
10938
|
+
};
|
|
10939
|
+
};
|
|
10940
|
+
type Config$3 = Plugin.Name<'swr'> & Plugin.Hooks & {
|
|
10941
|
+
/**
|
|
10942
|
+
* The casing convention to use for generated names.
|
|
10943
|
+
*
|
|
10944
|
+
* @default 'camelCase'
|
|
10945
|
+
*/
|
|
10946
|
+
case: StringCase;
|
|
10947
|
+
/**
|
|
10948
|
+
* Add comments from SDK functions to the generated SWR code?
|
|
10949
|
+
*
|
|
10950
|
+
* @default true
|
|
10951
|
+
*/
|
|
10952
|
+
comments: boolean;
|
|
10953
|
+
/**
|
|
10954
|
+
* Should the exports from the generated files be re-exported in the index barrel file?
|
|
10955
|
+
*
|
|
10956
|
+
* @default false
|
|
10957
|
+
*/
|
|
10958
|
+
exportFromIndex: boolean;
|
|
10959
|
+
/**
|
|
10960
|
+
* Resolved configuration for generated infinite query key helpers.
|
|
10961
|
+
*
|
|
10962
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/infiniteQueryOptions infiniteQueryOptions}
|
|
10963
|
+
*/
|
|
10964
|
+
infiniteQueryKeys: {
|
|
10965
|
+
/**
|
|
10966
|
+
* The casing convention to use for generated names.
|
|
10967
|
+
*
|
|
10968
|
+
* @default 'camelCase'
|
|
10969
|
+
*/
|
|
10970
|
+
case: StringCase;
|
|
10971
|
+
/**
|
|
10972
|
+
* Whether to generate infinite query key helpers.
|
|
10973
|
+
*
|
|
10974
|
+
* @default true
|
|
10975
|
+
*/
|
|
10976
|
+
enabled: boolean;
|
|
10977
|
+
/**
|
|
10978
|
+
* Custom naming pattern for generated infinite query key names. The name variable is obtained from the SDK function name.
|
|
10979
|
+
*
|
|
10980
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/infiniteQueryOptions infiniteQueryOptions}
|
|
10981
|
+
*
|
|
10982
|
+
* @default '{{name}}InfiniteQueryKey'
|
|
10983
|
+
*/
|
|
10984
|
+
name: StringName;
|
|
10985
|
+
/**
|
|
10986
|
+
* Whether to include operation tags in infinite query keys.
|
|
10987
|
+
* This will make query keys larger but provides better cache invalidation capabilities.
|
|
10988
|
+
*
|
|
10989
|
+
* @default false
|
|
10990
|
+
*/
|
|
10991
|
+
tags: boolean;
|
|
10992
|
+
};
|
|
10993
|
+
/**
|
|
10994
|
+
* Resolved configuration for generated infinite query options helpers.
|
|
10995
|
+
*
|
|
10996
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/infiniteQueryOptions infiniteQueryOptions}
|
|
10997
|
+
*/
|
|
10998
|
+
infiniteQueryOptions: {
|
|
10999
|
+
/**
|
|
11000
|
+
* The casing convention to use for generated names.
|
|
11001
|
+
*
|
|
11002
|
+
* @default 'camelCase'
|
|
11003
|
+
*/
|
|
11004
|
+
case: StringCase;
|
|
11005
|
+
/**
|
|
11006
|
+
* Whether to generate infinite query options helpers.
|
|
11007
|
+
*
|
|
11008
|
+
* @default true
|
|
11009
|
+
*/
|
|
11010
|
+
enabled: boolean;
|
|
11011
|
+
/**
|
|
11012
|
+
* Custom function to generate metadata for the operation.
|
|
11013
|
+
* Can return any valid meta object that will be included in the generated infinite query options.
|
|
11014
|
+
*
|
|
11015
|
+
* @param operation - The operation object containing all available metadata
|
|
11016
|
+
* @returns A meta object with any properties you want to include
|
|
11017
|
+
*
|
|
11018
|
+
* @example
|
|
11019
|
+
* ```typescript
|
|
11020
|
+
* meta: (operation) => ({
|
|
11021
|
+
* customField: operation.id,
|
|
11022
|
+
* isDeprecated: operation.deprecated,
|
|
11023
|
+
* tags: operation.tags,
|
|
11024
|
+
* customObject: {
|
|
11025
|
+
* method: operation.method,
|
|
11026
|
+
* path: operation.path
|
|
11027
|
+
* }
|
|
11028
|
+
* })
|
|
11029
|
+
* ```
|
|
11030
|
+
*
|
|
11031
|
+
* @default undefined
|
|
11032
|
+
*/
|
|
11033
|
+
meta: (operation: IR$1.OperationObject) => Record<string, unknown>;
|
|
11034
|
+
/**
|
|
11035
|
+
* Custom naming pattern for generated infinite query options names. The name variable is obtained from the SDK function name.
|
|
11036
|
+
*
|
|
11037
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/infiniteQueryOptions infiniteQueryOptions}
|
|
11038
|
+
*
|
|
11039
|
+
* @default '{{name}}InfiniteOptions'
|
|
11040
|
+
*/
|
|
11041
|
+
name: StringName;
|
|
11042
|
+
};
|
|
11043
|
+
/**
|
|
11044
|
+
* Resolved configuration for generated mutation options helpers.
|
|
11045
|
+
*
|
|
11046
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/useMutation useMutation}
|
|
11047
|
+
*/
|
|
11048
|
+
mutationOptions: {
|
|
11049
|
+
/**
|
|
11050
|
+
* The casing convention to use for generated names.
|
|
11051
|
+
*
|
|
11052
|
+
* @default 'camelCase'
|
|
11053
|
+
*/
|
|
11054
|
+
case: StringCase;
|
|
11055
|
+
/**
|
|
11056
|
+
* Whether to generate mutation options helpers.
|
|
11057
|
+
*
|
|
11058
|
+
* @default true
|
|
11059
|
+
*/
|
|
11060
|
+
enabled: boolean;
|
|
11061
|
+
/**
|
|
11062
|
+
* Custom function to generate metadata for the operation.
|
|
11063
|
+
* Can return any valid meta object that will be included in the generated mutation options.
|
|
11064
|
+
*
|
|
11065
|
+
* @param operation - The operation object containing all available metadata
|
|
11066
|
+
* @returns A meta object with any properties you want to include
|
|
11067
|
+
*
|
|
11068
|
+
* @example
|
|
11069
|
+
* ```typescript
|
|
11070
|
+
* meta: (operation) => ({
|
|
11071
|
+
* customField: operation.id,
|
|
11072
|
+
* isDeprecated: operation.deprecated,
|
|
11073
|
+
* tags: operation.tags,
|
|
11074
|
+
* customObject: {
|
|
11075
|
+
* method: operation.method,
|
|
11076
|
+
* path: operation.path
|
|
11077
|
+
* }
|
|
11078
|
+
* })
|
|
11079
|
+
* ```
|
|
11080
|
+
*
|
|
11081
|
+
* @default undefined
|
|
11082
|
+
*/
|
|
11083
|
+
meta: (operation: IR$1.OperationObject) => Record<string, unknown>;
|
|
11084
|
+
/**
|
|
11085
|
+
* Custom naming pattern for generated mutation options names. The name variable is obtained from the SDK function name.
|
|
11086
|
+
*
|
|
11087
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/useMutation useMutation}
|
|
11088
|
+
*
|
|
11089
|
+
* @default '{{name}}Mutation'
|
|
11090
|
+
*/
|
|
11091
|
+
name: StringName;
|
|
11092
|
+
};
|
|
11093
|
+
/**
|
|
11094
|
+
* Resolved configuration for generated query keys.
|
|
11095
|
+
*
|
|
11096
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/guides/query-keys Query Keys}
|
|
11097
|
+
*/
|
|
11098
|
+
queryKeys: {
|
|
11099
|
+
/**
|
|
11100
|
+
* The casing convention to use for generated names.
|
|
11101
|
+
*
|
|
11102
|
+
* @default 'camelCase'
|
|
11103
|
+
*/
|
|
11104
|
+
case: StringCase;
|
|
11105
|
+
/**
|
|
11106
|
+
* Whether to generate query keys.
|
|
11107
|
+
*
|
|
11108
|
+
* @default true
|
|
11109
|
+
*/
|
|
11110
|
+
enabled: boolean;
|
|
11111
|
+
/**
|
|
11112
|
+
* Custom naming pattern for generated query key names. The name variable is obtained from the SDK function name.
|
|
11113
|
+
*
|
|
11114
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/guides/query-keys Query Keys}
|
|
11115
|
+
*
|
|
11116
|
+
* @default '{{name}}QueryKey'
|
|
11117
|
+
*/
|
|
11118
|
+
name: StringName;
|
|
11119
|
+
/**
|
|
11120
|
+
* Whether to include operation tags in query keys.
|
|
11121
|
+
* This will make query keys larger but provides better cache invalidation capabilities.
|
|
11122
|
+
*
|
|
11123
|
+
* @default false
|
|
11124
|
+
*/
|
|
11125
|
+
tags: boolean;
|
|
11126
|
+
};
|
|
11127
|
+
/**
|
|
11128
|
+
* Resolved configuration for generated query options helpers.
|
|
11129
|
+
*
|
|
11130
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/queryOptions queryOptions}
|
|
11131
|
+
*/
|
|
11132
|
+
queryOptions: {
|
|
11133
|
+
/**
|
|
11134
|
+
* The casing convention to use for generated names.
|
|
11135
|
+
*
|
|
11136
|
+
* @default 'camelCase'
|
|
11137
|
+
*/
|
|
11138
|
+
case: StringCase;
|
|
11139
|
+
/**
|
|
11140
|
+
* Whether to generate query options helpers.
|
|
11141
|
+
*
|
|
11142
|
+
* @default true
|
|
11143
|
+
*/
|
|
11144
|
+
enabled: boolean;
|
|
11145
|
+
/**
|
|
11146
|
+
* Whether to export generated symbols.
|
|
11147
|
+
*
|
|
11148
|
+
* @default true
|
|
11149
|
+
*/
|
|
11150
|
+
exported: boolean;
|
|
11151
|
+
/**
|
|
11152
|
+
* Custom function to generate metadata for the operation.
|
|
11153
|
+
* Can return any valid meta object that will be included in the generated query options.
|
|
11154
|
+
*
|
|
11155
|
+
* @param operation - The operation object containing all available metadata
|
|
11156
|
+
* @returns A meta object with any properties you want to include
|
|
11157
|
+
*
|
|
11158
|
+
* @example
|
|
11159
|
+
* ```typescript
|
|
11160
|
+
* meta: (operation) => ({
|
|
11161
|
+
* customField: operation.id,
|
|
11162
|
+
* isDeprecated: operation.deprecated,
|
|
11163
|
+
* tags: operation.tags,
|
|
11164
|
+
* customObject: {
|
|
11165
|
+
* method: operation.method,
|
|
11166
|
+
* path: operation.path
|
|
11167
|
+
* }
|
|
11168
|
+
* })
|
|
11169
|
+
* ```
|
|
11170
|
+
*
|
|
11171
|
+
* @default undefined
|
|
11172
|
+
*/
|
|
11173
|
+
meta: (operation: IR$1.OperationObject) => Record<string, unknown>;
|
|
11174
|
+
/**
|
|
11175
|
+
* Custom naming pattern for generated query options names. The name variable is obtained from the SDK function name.
|
|
11176
|
+
*
|
|
11177
|
+
* See {@link https://tanstack.com/query/v5/docs/framework/react/reference/queryOptions queryOptions}
|
|
11178
|
+
*
|
|
11179
|
+
* @default '{{name}}Options'
|
|
11180
|
+
*/
|
|
11181
|
+
name: StringName;
|
|
11182
|
+
};
|
|
11183
|
+
/**
|
|
11184
|
+
* Configuration for generated `useSwr()` function helpers.
|
|
11185
|
+
*
|
|
11186
|
+
* See {@link https://swr.vercel.app/docs/api API}
|
|
11187
|
+
*/
|
|
11188
|
+
useSwr: {
|
|
11189
|
+
/**
|
|
11190
|
+
* The casing convention to use for generated names.
|
|
11191
|
+
*
|
|
11192
|
+
* @default 'camelCase'
|
|
11193
|
+
*/
|
|
11194
|
+
case: StringCase;
|
|
11195
|
+
/**
|
|
11196
|
+
* Whether to generate `useSwr()` function helpers.
|
|
11197
|
+
*
|
|
11198
|
+
* @default true
|
|
11199
|
+
*/
|
|
11200
|
+
enabled: boolean;
|
|
11201
|
+
/**
|
|
11202
|
+
* Custom naming pattern for generated `useSwr()` function names. The name variable is
|
|
11203
|
+
* obtained from the SDK function name.
|
|
11204
|
+
*
|
|
11205
|
+
* See {@link https://swr.vercel.app/docs/api API}
|
|
11206
|
+
*
|
|
11207
|
+
* @default 'use{{name}}'
|
|
11208
|
+
*/
|
|
11209
|
+
name: StringName;
|
|
11210
|
+
};
|
|
11211
|
+
};
|
|
11212
|
+
type SwrPlugin = DefinePlugin<UserConfig$3, Config$3>;
|
|
11213
|
+
//#endregion
|
|
11214
|
+
//#region src/plugins/valibot/shared/types.d.ts
|
|
11215
|
+
type ValidatorArgs$1 = {
|
|
11216
|
+
operation: IR$1.OperationObject;
|
|
11217
|
+
plugin: ValibotPlugin['Instance'];
|
|
11218
|
+
};
|
|
11219
|
+
//#endregion
|
|
11220
|
+
//#region src/plugins/valibot/api.d.ts
|
|
11221
|
+
type IApi$1 = {
|
|
11222
|
+
createRequestValidator: (args: ValidatorArgs$1) => TsDsl | undefined;
|
|
11223
|
+
createResponseValidator: (args: ValidatorArgs$1) => TsDsl | undefined;
|
|
11224
|
+
};
|
|
11225
|
+
//#endregion
|
|
11226
|
+
//#region src/plugins/valibot/types.d.ts
|
|
11227
|
+
type UserConfig$2 = Plugin.Name<'valibot'> & Plugin.Hooks & {
|
|
11228
|
+
/**
|
|
11229
|
+
* The casing convention to use for generated names.
|
|
11230
|
+
*
|
|
11231
|
+
* @default 'camelCase'
|
|
11232
|
+
*/
|
|
11233
|
+
case?: StringCase;
|
|
11234
|
+
/**
|
|
11235
|
+
* Add comments from input to the generated Valibot schemas?
|
|
11236
|
+
*
|
|
11237
|
+
* @default true
|
|
11238
|
+
*/
|
|
11239
|
+
comments?: boolean;
|
|
11240
|
+
/**
|
|
11241
|
+
* Configuration for reusable schema definitions.
|
|
11242
|
+
*
|
|
11243
|
+
* Controls generation of shared Valibot schemas that can be referenced
|
|
11244
|
+
* across requests and responses.
|
|
11245
|
+
*
|
|
11246
|
+
* Can be:
|
|
11247
|
+
* - `boolean`: Shorthand for `{ enabled: boolean }`
|
|
11248
|
+
* - `string` or `function`: Shorthand for `{ name: string | function }`
|
|
11249
|
+
* - `object`: Full configuration object
|
|
11250
|
+
*/
|
|
11251
|
+
definitions?: boolean | StringName | {
|
|
11252
|
+
/**
|
|
11253
|
+
* The casing convention to use for generated names.
|
|
11254
|
+
*
|
|
11255
|
+
* @default 'camelCase'
|
|
11256
|
+
*/
|
|
11257
|
+
case?: StringCase;
|
|
11258
|
+
/**
|
|
11259
|
+
* Whether to generate Valibot schemas for reusable definitions.
|
|
11260
|
+
*
|
|
11261
|
+
* @default true
|
|
11262
|
+
*/
|
|
11263
|
+
enabled?: boolean;
|
|
11264
|
+
/**
|
|
11265
|
+
* Custom naming pattern for generated schema names. The name variable
|
|
11266
|
+
* is obtained from the schema name.
|
|
11267
|
+
*
|
|
11268
|
+
* @default 'v{{name}}'
|
|
11269
|
+
*/
|
|
11270
|
+
name?: StringName;
|
|
11271
|
+
};
|
|
11272
|
+
/**
|
|
11273
|
+
* Should the exports from the generated files be re-exported in the index
|
|
11274
|
+
* barrel file?
|
|
11275
|
+
*
|
|
11276
|
+
* @default false
|
|
11277
|
+
*/
|
|
11278
|
+
exportFromIndex?: boolean;
|
|
11279
|
+
/**
|
|
11280
|
+
* Enable Valibot metadata support? It's often useful to associate a schema
|
|
11281
|
+
* with some additional metadata for documentation, code generation, AI
|
|
11282
|
+
* structured outputs, form validation, and other purposes.
|
|
11283
|
+
*
|
|
11284
|
+
* @default false
|
|
11285
|
+
*/
|
|
11286
|
+
metadata?: boolean;
|
|
11287
|
+
/**
|
|
11288
|
+
* Configuration for request-specific Valibot schemas.
|
|
11289
|
+
*
|
|
11290
|
+
* Controls generation of Valibot schemas for request bodies, query
|
|
11291
|
+
* parameters, path parameters, and headers.
|
|
11292
|
+
*
|
|
11293
|
+
* Can be:
|
|
11294
|
+
* - `boolean`: Shorthand for `{ enabled: boolean }`
|
|
11295
|
+
* - `string` or `function`: Shorthand for `{ name: string | function }`
|
|
11296
|
+
* - `object`: Full configuration object
|
|
11297
|
+
*/
|
|
11298
|
+
requests?: boolean | StringName | {
|
|
11299
|
+
/**
|
|
11300
|
+
* The casing convention to use for generated names.
|
|
11301
|
+
*
|
|
11302
|
+
* @default 'camelCase'
|
|
11303
|
+
*/
|
|
11304
|
+
case?: StringCase;
|
|
11305
|
+
/**
|
|
11306
|
+
* Whether to generate Valibot schemas for request definitions.
|
|
11307
|
+
*
|
|
11308
|
+
* @default true
|
|
11309
|
+
*/
|
|
11310
|
+
enabled?: boolean;
|
|
11311
|
+
/**
|
|
11312
|
+
* Custom naming pattern for generated schema names. The name variable
|
|
11313
|
+
* is obtained from the operation name.
|
|
11314
|
+
*
|
|
11315
|
+
* @default 'v{{name}}Data'
|
|
11316
|
+
*/
|
|
11317
|
+
name?: StringName;
|
|
11318
|
+
};
|
|
11319
|
+
/**
|
|
11320
|
+
* Configuration for response-specific Valibot schemas.
|
|
11321
|
+
*
|
|
11322
|
+
* Controls generation of Valibot schemas for response bodies, error
|
|
11323
|
+
* responses, and status codes.
|
|
11324
|
+
*
|
|
11325
|
+
* Can be:
|
|
11326
|
+
* - `boolean`: Shorthand for `{ enabled: boolean }`
|
|
11327
|
+
* - `string` or `function`: Shorthand for `{ name: string | function }`
|
|
11328
|
+
* - `object`: Full configuration object
|
|
11329
|
+
*/
|
|
11330
|
+
responses?: boolean | StringName | {
|
|
11331
|
+
/**
|
|
11332
|
+
* The casing convention to use for generated names.
|
|
11333
|
+
*
|
|
11334
|
+
* @default 'camelCase'
|
|
11335
|
+
*/
|
|
11336
|
+
case?: StringCase;
|
|
11337
|
+
/**
|
|
11338
|
+
* Whether to generate Valibot schemas for response definitions.
|
|
11339
|
+
*
|
|
11340
|
+
* @default true
|
|
11341
|
+
*/
|
|
11342
|
+
enabled?: boolean;
|
|
11343
|
+
/**
|
|
11344
|
+
* Custom naming pattern for generated schema names. The name variable
|
|
11345
|
+
* is obtained from the operation name.
|
|
11346
|
+
*
|
|
11347
|
+
* @default 'v{{name}}Response'
|
|
11348
|
+
*/
|
|
11349
|
+
name?: StringName;
|
|
11350
|
+
};
|
|
11351
|
+
/**
|
|
11352
|
+
* Configuration for webhook-specific Valibot schemas.
|
|
11353
|
+
*
|
|
11354
|
+
* Controls generation of Valibot schemas for webhook payloads.
|
|
11355
|
+
*
|
|
11356
|
+
* Can be:
|
|
11357
|
+
* - `boolean`: Shorthand for `{ enabled: boolean }`
|
|
11358
|
+
* - `string` or `function`: Shorthand for `{ name: string | function }`
|
|
11359
|
+
* - `object`: Full configuration object
|
|
11360
|
+
*
|
|
11361
|
+
* @default true
|
|
11362
|
+
*/
|
|
11363
|
+
webhooks?: boolean | StringName | {
|
|
11364
|
+
/**
|
|
11365
|
+
* The casing convention to use for generated names.
|
|
11366
|
+
*
|
|
11367
|
+
* @default 'camelCase'
|
|
11368
|
+
*/
|
|
11369
|
+
case?: StringCase;
|
|
11370
|
+
/**
|
|
11371
|
+
* Whether to generate Valibot schemas for webhook definitions.
|
|
11372
|
+
*
|
|
11373
|
+
* @default true
|
|
11374
|
+
*/
|
|
11375
|
+
enabled?: boolean;
|
|
11376
|
+
/**
|
|
11377
|
+
* Custom naming pattern for generated schema names. The name variable
|
|
11378
|
+
* is obtained from the webhook key.
|
|
11379
|
+
*
|
|
11380
|
+
* @default 'v{{name}}WebhookRequest'
|
|
11381
|
+
*/
|
|
11382
|
+
name?: StringName;
|
|
11383
|
+
};
|
|
11384
|
+
};
|
|
11385
|
+
type Config$2 = Plugin.Name<'valibot'> & Plugin.Hooks & {
|
|
11386
|
+
/**
|
|
11387
|
+
* The casing convention to use for generated names.
|
|
11388
|
+
*
|
|
11389
|
+
* @default 'camelCase'
|
|
11390
|
+
*/
|
|
10868
11391
|
case: StringCase;
|
|
10869
11392
|
/**
|
|
10870
11393
|
* Add comments from input to the generated Valibot schemas?
|
|
@@ -10995,7 +11518,7 @@ type Config$2 = Plugin.Name<'valibot'> & Plugin.Hooks & {
|
|
|
10995
11518
|
name: StringName;
|
|
10996
11519
|
};
|
|
10997
11520
|
};
|
|
10998
|
-
type ValibotPlugin = DefinePlugin<UserConfig$
|
|
11521
|
+
type ValibotPlugin = DefinePlugin<UserConfig$2, Config$2, IApi$1>;
|
|
10999
11522
|
//#endregion
|
|
11000
11523
|
//#region src/plugins/zod/shared/types.d.ts
|
|
11001
11524
|
type ValidatorArgs = {
|
|
@@ -11005,12 +11528,12 @@ type ValidatorArgs = {
|
|
|
11005
11528
|
//#endregion
|
|
11006
11529
|
//#region src/plugins/zod/api.d.ts
|
|
11007
11530
|
type IApi = {
|
|
11008
|
-
createRequestValidator: (args: ValidatorArgs) =>
|
|
11009
|
-
createResponseValidator: (args: ValidatorArgs) =>
|
|
11531
|
+
createRequestValidator: (args: ValidatorArgs) => TsDsl | undefined;
|
|
11532
|
+
createResponseValidator: (args: ValidatorArgs) => TsDsl | undefined;
|
|
11010
11533
|
};
|
|
11011
11534
|
//#endregion
|
|
11012
11535
|
//#region src/plugins/zod/types.d.ts
|
|
11013
|
-
type UserConfig$
|
|
11536
|
+
type UserConfig$1 = Plugin.Name<'zod'> & Plugin.Hooks & {
|
|
11014
11537
|
/**
|
|
11015
11538
|
* The casing convention to use for generated names.
|
|
11016
11539
|
*
|
|
@@ -11715,7 +12238,7 @@ type Config$1 = Plugin.Name<'zod'> & Plugin.Hooks & {
|
|
|
11715
12238
|
};
|
|
11716
12239
|
};
|
|
11717
12240
|
};
|
|
11718
|
-
type ZodPlugin = DefinePlugin<UserConfig$
|
|
12241
|
+
type ZodPlugin = DefinePlugin<UserConfig$1, Config$1, IApi>;
|
|
11719
12242
|
//#endregion
|
|
11720
12243
|
//#region src/plugins/config.d.ts
|
|
11721
12244
|
interface PluginConfigMap {
|
|
@@ -11723,6 +12246,7 @@ interface PluginConfigMap {
|
|
|
11723
12246
|
'@hey-api/client-angular': HeyApiClientAngularPlugin['Types'];
|
|
11724
12247
|
'@hey-api/client-axios': HeyApiClientAxiosPlugin['Types'];
|
|
11725
12248
|
'@hey-api/client-fetch': HeyApiClientFetchPlugin['Types'];
|
|
12249
|
+
'@hey-api/client-ky': HeyApiClientKyPlugin['Types'];
|
|
11726
12250
|
'@hey-api/client-next': HeyApiClientNextPlugin['Types'];
|
|
11727
12251
|
'@hey-api/client-nuxt': HeyApiClientNuxtPlugin['Types'];
|
|
11728
12252
|
'@hey-api/client-ofetch': HeyApiClientOfetchPlugin['Types'];
|
|
@@ -11738,6 +12262,7 @@ interface PluginConfigMap {
|
|
|
11738
12262
|
'@tanstack/vue-query': TanStackVueQueryPlugin['Types'];
|
|
11739
12263
|
arktype: ArktypePlugin['Types'];
|
|
11740
12264
|
fastify: FastifyPlugin['Types'];
|
|
12265
|
+
swr: SwrPlugin['Types'];
|
|
11741
12266
|
valibot: ValibotPlugin['Types'];
|
|
11742
12267
|
zod: ZodPlugin['Types'];
|
|
11743
12268
|
}
|
|
@@ -11926,14 +12451,13 @@ type WalkEvent<T extends IrTopLevelKind = IrTopLevelKind> = Extract<WalkEvents,
|
|
|
11926
12451
|
//#region src/plugins/shared/utils/instance.d.ts
|
|
11927
12452
|
declare class PluginInstance<T extends Plugin.Types = Plugin.Types> {
|
|
11928
12453
|
api: T['api'];
|
|
11929
|
-
config: Omit<T['resolvedConfig'], 'name'
|
|
12454
|
+
config: Omit<T['resolvedConfig'], 'name'>;
|
|
11930
12455
|
context: Context;
|
|
11931
12456
|
dependencies: Required<Plugin.Config<T>>['dependencies'];
|
|
11932
12457
|
private eventHooks;
|
|
11933
12458
|
gen: IProject;
|
|
11934
12459
|
private handler;
|
|
11935
12460
|
name: T['resolvedConfig']['name'];
|
|
11936
|
-
output: string;
|
|
11937
12461
|
/**
|
|
11938
12462
|
* The package metadata and utilities for the current context, constructed
|
|
11939
12463
|
* from the provided dependencies. Used for managing package-related
|
|
@@ -11946,7 +12470,6 @@ declare class PluginInstance<T extends Plugin.Types = Plugin.Types> {
|
|
|
11946
12470
|
context: Context<OpenApi.V2_0_X | OpenApi.V3_0_X | OpenApi.V3_1_X>;
|
|
11947
12471
|
gen: IProject;
|
|
11948
12472
|
name: string;
|
|
11949
|
-
output: string;
|
|
11950
12473
|
});
|
|
11951
12474
|
/**
|
|
11952
12475
|
* Iterates over various input elements as specified by the event types, in
|
|
@@ -12197,11 +12720,11 @@ type Hooks = {
|
|
|
12197
12720
|
};
|
|
12198
12721
|
//#endregion
|
|
12199
12722
|
//#region src/plugins/types.d.ts
|
|
12200
|
-
type PluginClientNames = '@hey-api/client-angular' | '@hey-api/client-axios' | '@hey-api/client-fetch' | '@hey-api/client-next' | '@hey-api/client-nuxt' | '@hey-api/client-ofetch';
|
|
12723
|
+
type PluginClientNames = '@hey-api/client-angular' | '@hey-api/client-axios' | '@hey-api/client-fetch' | '@hey-api/client-ky' | '@hey-api/client-next' | '@hey-api/client-nuxt' | '@hey-api/client-ofetch';
|
|
12201
12724
|
type PluginValidatorNames = 'arktype' | 'valibot' | 'zod';
|
|
12202
|
-
type PluginNames = PluginClientNames | '@angular/common' | '@hey-api/schemas' | '@hey-api/sdk' | '@hey-api/transformers' | '@hey-api/typescript' | '@pinia/colada' | '@tanstack/angular-query-experimental' | '@tanstack/react-query' | '@tanstack/solid-query' | '@tanstack/svelte-query' | '@tanstack/vue-query' | 'fastify' | PluginValidatorNames;
|
|
12725
|
+
type PluginNames = PluginClientNames | '@angular/common' | '@hey-api/schemas' | '@hey-api/sdk' | '@hey-api/transformers' | '@hey-api/typescript' | '@pinia/colada' | '@tanstack/angular-query-experimental' | '@tanstack/react-query' | '@tanstack/solid-query' | '@tanstack/svelte-query' | '@tanstack/vue-query' | 'fastify' | 'swr' | PluginValidatorNames;
|
|
12203
12726
|
type AnyPluginName = PluginNames | (string & {});
|
|
12204
|
-
type PluginTag = 'client' | 'transformer' | 'validator';
|
|
12727
|
+
type PluginTag = 'client' | 'sdk' | 'transformer' | 'validator';
|
|
12205
12728
|
type PluginContext = {
|
|
12206
12729
|
package: Package;
|
|
12207
12730
|
pluginByTag: <T extends AnyPluginName | boolean = AnyPluginName>(tag: PluginTag, props?: {
|
|
@@ -12232,7 +12755,7 @@ type BaseConfig = {
|
|
|
12232
12755
|
*/
|
|
12233
12756
|
declare namespace Plugin {
|
|
12234
12757
|
export type Config<T extends Types> = Pick<T, 'api'> & {
|
|
12235
|
-
config: Omit<T['config'], 'name'
|
|
12758
|
+
config: Omit<T['config'], 'name'>;
|
|
12236
12759
|
/**
|
|
12237
12760
|
* Dependency plugins will be always processed, regardless of whether user
|
|
12238
12761
|
* explicitly defines them in their `plugins` config.
|
|
@@ -12240,7 +12763,6 @@ declare namespace Plugin {
|
|
|
12240
12763
|
dependencies?: ReadonlyArray<AnyPluginName>;
|
|
12241
12764
|
handler: Handler<T>;
|
|
12242
12765
|
name: T['config']['name'];
|
|
12243
|
-
output?: NonNullable<T['config']['output']>;
|
|
12244
12766
|
/**
|
|
12245
12767
|
* Resolves static configuration values into their runtime equivalents. For
|
|
12246
12768
|
* example, when `validator` is set to `true`, it figures out which plugin
|
|
@@ -12250,25 +12772,11 @@ declare namespace Plugin {
|
|
|
12250
12772
|
dependencies: Set<AnyPluginName>;
|
|
12251
12773
|
}, context: PluginContext) => void;
|
|
12252
12774
|
/**
|
|
12253
|
-
*
|
|
12775
|
+
* Tags can be used to help with deciding plugin order and resolving
|
|
12254
12776
|
* plugin configuration options.
|
|
12255
12777
|
*/
|
|
12256
12778
|
tags?: ReadonlyArray<PluginTag>;
|
|
12257
12779
|
};
|
|
12258
|
-
export type ConfigWithName<T extends Types> = Omit<Config$14<T>, 'config'> & {
|
|
12259
|
-
config: Omit<T['config'], 'output'>;
|
|
12260
|
-
};
|
|
12261
|
-
|
|
12262
|
-
/** @deprecated use `definePluginConfig()` instead */
|
|
12263
|
-
export type DefineConfig<Config$14 extends BaseConfig, ResolvedConfig extends BaseConfig = Config$14> = (config?: UserConfig<Omit<Config$14, 'name'>>) => Omit<Plugin.Config<Config$14, ResolvedConfig>, 'name'> & {
|
|
12264
|
-
/**
|
|
12265
|
-
* Cast name to `any` so it doesn't throw type error in `plugins` array.
|
|
12266
|
-
* We could allow any `string` as plugin `name` in the object syntax, but
|
|
12267
|
-
* that TypeScript trick would cause all string methods to appear as
|
|
12268
|
-
* suggested auto completions, which is undesirable.
|
|
12269
|
-
*/
|
|
12270
|
-
name: any;
|
|
12271
|
-
};
|
|
12272
12780
|
|
|
12273
12781
|
/**
|
|
12274
12782
|
* Generic wrapper for plugin hooks.
|
|
@@ -12277,27 +12785,22 @@ declare namespace Plugin {
|
|
|
12277
12785
|
export interface Name<Name extends PluginNames> {
|
|
12278
12786
|
name: Name;
|
|
12279
12787
|
}
|
|
12280
|
-
export type Types<Config$
|
|
12788
|
+
export type Types<Config$15 extends BaseConfig = BaseConfig, ResolvedConfig extends BaseConfig = Config$15, Api extends BaseApi = never> = ([Api] extends [never] ? {
|
|
12281
12789
|
api?: BaseApi;
|
|
12282
12790
|
} : {
|
|
12283
12791
|
api: Api;
|
|
12284
12792
|
}) & {
|
|
12285
|
-
config: Config$
|
|
12793
|
+
config: Config$15;
|
|
12286
12794
|
resolvedConfig: ResolvedConfig;
|
|
12287
12795
|
};
|
|
12288
|
-
|
|
12289
|
-
/**
|
|
12290
|
-
* Users cannot modify output file path to avoid risk of conflicts.
|
|
12291
|
-
*/
|
|
12292
|
-
export type UserConfig<Config$14 extends BaseConfig> = Omit<Config$14, 'output'>;
|
|
12293
12796
|
}
|
|
12294
|
-
type DefinePlugin<Config$
|
|
12295
|
-
Config: Plugin.Config<Plugin.Types<Config$
|
|
12797
|
+
type DefinePlugin<Config$15 extends BaseConfig = BaseConfig, ResolvedConfig extends BaseConfig = Config$15, Api extends BaseApi = never> = {
|
|
12798
|
+
Config: Plugin.Config<Plugin.Types<Config$15, ResolvedConfig, Api>>;
|
|
12296
12799
|
Handler: (args: {
|
|
12297
|
-
plugin: PluginInstance<Plugin.Types<Config$
|
|
12800
|
+
plugin: PluginInstance<Plugin.Types<Config$15, ResolvedConfig, Api>>;
|
|
12298
12801
|
}) => void;
|
|
12299
|
-
Instance: PluginInstance<Plugin.Types<Config$
|
|
12300
|
-
Types: Plugin.Types<Config$
|
|
12802
|
+
Instance: PluginInstance<Plugin.Types<Config$15, ResolvedConfig, Api>>;
|
|
12803
|
+
Types: Plugin.Types<Config$15, ResolvedConfig, Api>;
|
|
12301
12804
|
};
|
|
12302
12805
|
//#endregion
|
|
12303
12806
|
//#region src/types/input.d.ts
|
|
@@ -13266,7 +13769,7 @@ type Patch = {
|
|
|
13266
13769
|
};
|
|
13267
13770
|
//#endregion
|
|
13268
13771
|
//#region src/types/config.d.ts
|
|
13269
|
-
interface UserConfig
|
|
13772
|
+
interface UserConfig {
|
|
13270
13773
|
/**
|
|
13271
13774
|
* Path to the config file. Set this value if you don't use the default
|
|
13272
13775
|
* config file name, or it's not located in the project root.
|
|
@@ -13326,7 +13829,7 @@ interface UserConfig$1 {
|
|
|
13326
13829
|
*
|
|
13327
13830
|
* @default ['@hey-api/typescript', '@hey-api/sdk']
|
|
13328
13831
|
*/
|
|
13329
|
-
plugins?: ReadonlyArray<PluginNames | { [K in PluginNames]:
|
|
13832
|
+
plugins?: ReadonlyArray<PluginNames | { [K in PluginNames]: PluginConfigMap[K]['config'] & {
|
|
13330
13833
|
name: K;
|
|
13331
13834
|
} }[PluginNames]>;
|
|
13332
13835
|
/**
|
|
@@ -13334,7 +13837,7 @@ interface UserConfig$1 {
|
|
|
13334
13837
|
*/
|
|
13335
13838
|
watch?: boolean | number | Watch;
|
|
13336
13839
|
}
|
|
13337
|
-
type Config = Omit<Required<UserConfig
|
|
13840
|
+
type Config = Omit<Required<UserConfig>, 'input' | 'logs' | 'output' | 'parser' | 'plugins' | 'watch'> & {
|
|
13338
13841
|
/**
|
|
13339
13842
|
* Path to the input specification.
|
|
13340
13843
|
*/
|
|
@@ -13350,8 +13853,8 @@ type Config = Omit<Required<UserConfig$1>, 'input' | 'logs' | 'output' | 'parser
|
|
|
13350
13853
|
*/
|
|
13351
13854
|
parser: Parser;
|
|
13352
13855
|
pluginOrder: ReadonlyArray<keyof PluginConfigMap>;
|
|
13353
|
-
plugins: { [K in PluginNames]?: Plugin.
|
|
13856
|
+
plugins: { [K in PluginNames]?: Plugin.Config<PluginConfigMap[K]> };
|
|
13354
13857
|
};
|
|
13355
13858
|
//#endregion
|
|
13356
|
-
export { MaybeArray as S, Client as _, Plugin as a, IR$1 as b, OpenApiOperationObject as c, OpenApiResponseObject as d, OpenApiSchemaObject as f, ExpressionTransformer as g, TypeTransformer as h, DefinePlugin as i, OpenApiParameterObject as l, Logger as m, UserConfig
|
|
13357
|
-
//# sourceMappingURL=config-
|
|
13859
|
+
export { MaybeArray as S, Client as _, Plugin as a, IR$1 as b, OpenApiOperationObject as c, OpenApiResponseObject as d, OpenApiSchemaObject as f, ExpressionTransformer as g, TypeTransformer as h, DefinePlugin as i, OpenApiParameterObject as l, Logger as m, UserConfig as n, OpenApi as o, Context as p, Input as r, OpenApiMetaObject as s, Config as t, OpenApiRequestBodyObject as u, PluginHandler as v, LazyOrAsync as x, StringCase as y };
|
|
13860
|
+
//# sourceMappingURL=config-CQeoZYf_.d.cts.map
|