@kubb/plugin-vue-query 4.4.0 → 4.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. package/dist/{components-DoPUxAFs.cjs → components-CvorLYVT.cjs} +214 -214
  2. package/dist/components-CvorLYVT.cjs.map +1 -0
  3. package/dist/{components-B8p5782n.js → components-kADKAHgd.js} +213 -213
  4. package/dist/components-kADKAHgd.js.map +1 -0
  5. package/dist/components.cjs +1 -1
  6. package/dist/components.d.cts +114 -114
  7. package/dist/components.d.ts +114 -114
  8. package/dist/components.js +1 -1
  9. package/dist/{generators-a7s1tUe0.cjs → generators-B7BEw8ZB.cjs} +206 -143
  10. package/dist/generators-B7BEw8ZB.cjs.map +1 -0
  11. package/dist/{generators-CxbnV3X_.js → generators-DHkXUh19.js} +203 -141
  12. package/dist/generators-DHkXUh19.js.map +1 -0
  13. package/dist/generators.cjs +2 -2
  14. package/dist/generators.d.cts +5 -5
  15. package/dist/generators.d.ts +5 -5
  16. package/dist/generators.js +2 -2
  17. package/dist/index.cjs +18 -3
  18. package/dist/index.cjs.map +1 -1
  19. package/dist/index.d.cts +1 -1
  20. package/dist/index.d.ts +1 -1
  21. package/dist/index.js +16 -3
  22. package/dist/index.js.map +1 -1
  23. package/dist/{types-B1jcCl0j.d.cts → types-BfKwA3Gv.d.cts} +188 -310
  24. package/dist/{types-DDtBZP0d.d.ts → types-I09wleY8.d.ts} +188 -310
  25. package/package.json +18 -14
  26. package/src/components/QueryOptions.tsx +1 -1
  27. package/src/components/index.ts +3 -3
  28. package/src/generators/index.ts +2 -2
  29. package/src/generators/infiniteQueryGenerator.tsx +35 -11
  30. package/src/generators/mutationGenerator.tsx +34 -9
  31. package/src/generators/queryGenerator.tsx +35 -11
  32. package/src/plugin.ts +24 -1
  33. package/src/types.ts +4 -3
  34. package/dist/components-B8p5782n.js.map +0 -1
  35. package/dist/components-DoPUxAFs.cjs.map +0 -1
  36. package/dist/generators-CxbnV3X_.js.map +0 -1
  37. package/dist/generators-a7s1tUe0.cjs.map +0 -1
@@ -1,37 +1,9 @@
1
- import { a as OperationSchemas, c as Operation, i as Transformer, r as PluginVueQuery, t as Infinite } from "./types-DDtBZP0d.js";
1
+ import { c as Operation, i as Transformer, o as OperationSchemas, r as PluginVueQuery, t as Infinite } from "./types-I09wleY8.js";
2
2
  import { FunctionParams } from "@kubb/react-fabric";
3
3
  import { KubbNode } from "@kubb/react-fabric/types";
4
4
 
5
- //#region src/components/Mutation.d.ts
5
+ //#region src/components/InfiniteQuery.d.ts
6
6
  type Props$6 = {
7
- /**
8
- * Name of the function
9
- */
10
- name: string;
11
- typeName: string;
12
- clientName: string;
13
- mutationKeyName: string;
14
- typeSchemas: OperationSchemas;
15
- operation: Operation;
16
- paramsCasing: PluginVueQuery['resolvedOptions']['paramsCasing'];
17
- paramsType: PluginVueQuery['resolvedOptions']['paramsType'];
18
- dataReturnType: PluginVueQuery['resolvedOptions']['client']['dataReturnType'];
19
- pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
20
- };
21
- declare function Mutation({
22
- name,
23
- clientName,
24
- paramsCasing,
25
- paramsType,
26
- pathParamsType,
27
- dataReturnType,
28
- typeSchemas,
29
- operation,
30
- mutationKeyName
31
- }: Props$6): KubbNode;
32
- //#endregion
33
- //#region src/components/Query.d.ts
34
- type Props$5 = {
35
7
  /**
36
8
  * Name of the function
37
9
  */
@@ -53,141 +25,128 @@ type GetParamsProps$5 = {
53
25
  dataReturnType: PluginVueQuery['resolvedOptions']['client']['dataReturnType'];
54
26
  typeSchemas: OperationSchemas;
55
27
  };
56
- declare function Query({
28
+ declare function InfiniteQuery({
57
29
  name,
58
30
  queryKeyTypeName,
59
31
  queryOptionsName,
60
32
  queryKeyName,
61
33
  paramsType,
62
- paramsCasing,
63
34
  pathParamsType,
35
+ paramsCasing,
64
36
  dataReturnType,
65
37
  typeSchemas,
66
38
  operation
67
- }: Props$5): KubbNode;
68
- declare namespace Query {
39
+ }: Props$6): KubbNode;
40
+ declare namespace InfiniteQuery {
69
41
  var getParams: ({
70
- paramsCasing,
71
42
  paramsType,
43
+ paramsCasing,
72
44
  pathParamsType,
73
45
  dataReturnType,
74
46
  typeSchemas
75
47
  }: GetParamsProps$5) => FunctionParams;
76
48
  }
77
49
  //#endregion
78
- //#region src/components/QueryKey.d.ts
79
- type Props$4 = {
50
+ //#region src/components/InfiniteQueryOptions.d.ts
51
+ type Props$5 = {
80
52
  name: string;
81
- typeName: string;
53
+ clientName: string;
54
+ queryKeyName: string;
82
55
  typeSchemas: OperationSchemas;
83
- operation: Operation;
84
56
  paramsCasing: PluginVueQuery['resolvedOptions']['paramsCasing'];
57
+ paramsType: PluginVueQuery['resolvedOptions']['paramsType'];
85
58
  pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
86
- transformer: Transformer | undefined;
59
+ dataReturnType: PluginVueQuery['resolvedOptions']['client']['dataReturnType'];
60
+ initialPageParam: Infinite['initialPageParam'];
61
+ cursorParam: Infinite['cursorParam'];
62
+ queryParam: Infinite['queryParam'];
87
63
  };
88
64
  type GetParamsProps$4 = {
89
65
  paramsCasing: PluginVueQuery['resolvedOptions']['paramsCasing'];
66
+ paramsType: PluginVueQuery['resolvedOptions']['paramsType'];
90
67
  pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
91
68
  typeSchemas: OperationSchemas;
92
69
  };
93
- declare function QueryKey({
70
+ declare function InfiniteQueryOptions({
94
71
  name,
72
+ clientName,
73
+ initialPageParam,
74
+ cursorParam,
95
75
  typeSchemas,
76
+ paramsType,
96
77
  paramsCasing,
78
+ dataReturnType,
97
79
  pathParamsType,
98
- operation,
99
- typeName,
100
- transformer
101
- }: Props$4): KubbNode;
102
- declare namespace QueryKey {
80
+ queryParam,
81
+ queryKeyName
82
+ }: Props$5): KubbNode;
83
+ declare namespace InfiniteQueryOptions {
103
84
  var getParams: ({
104
- pathParamsType,
85
+ paramsType,
105
86
  paramsCasing,
87
+ pathParamsType,
106
88
  typeSchemas
107
89
  }: GetParamsProps$4) => FunctionParams;
108
- var getTransformer: Transformer;
109
90
  }
110
91
  //#endregion
111
- //#region src/components/QueryOptions.d.ts
112
- type Props$3 = {
92
+ //#region src/components/Mutation.d.ts
93
+ type Props$4 = {
94
+ /**
95
+ * Name of the function
96
+ */
113
97
  name: string;
98
+ typeName: string;
114
99
  clientName: string;
115
- queryKeyName: string;
100
+ mutationKeyName: string;
116
101
  typeSchemas: OperationSchemas;
102
+ operation: Operation;
117
103
  paramsCasing: PluginVueQuery['resolvedOptions']['paramsCasing'];
118
104
  paramsType: PluginVueQuery['resolvedOptions']['paramsType'];
119
- pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
120
105
  dataReturnType: PluginVueQuery['resolvedOptions']['client']['dataReturnType'];
121
- };
122
- type GetParamsProps$3 = {
123
- paramsCasing: PluginVueQuery['resolvedOptions']['paramsCasing'];
124
- paramsType: PluginVueQuery['resolvedOptions']['paramsType'];
125
106
  pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
126
- typeSchemas: OperationSchemas;
127
107
  };
128
- declare function QueryOptions({
108
+ declare function Mutation({
129
109
  name,
130
110
  clientName,
131
- dataReturnType,
132
- typeSchemas,
133
111
  paramsCasing,
134
112
  paramsType,
135
113
  pathParamsType,
136
- queryKeyName
137
- }: Props$3): KubbNode;
138
- declare namespace QueryOptions {
139
- var getParams: ({
140
- paramsType,
141
- paramsCasing,
142
- pathParamsType,
143
- typeSchemas
144
- }: GetParamsProps$3) => FunctionParams;
145
- }
114
+ dataReturnType,
115
+ typeSchemas,
116
+ operation,
117
+ mutationKeyName
118
+ }: Props$4): KubbNode;
146
119
  //#endregion
147
- //#region src/components/InfiniteQueryOptions.d.ts
148
- type Props$2 = {
120
+ //#region src/components/MutationKey.d.ts
121
+ type Props$3 = {
149
122
  name: string;
150
- clientName: string;
151
- queryKeyName: string;
123
+ typeName: string;
152
124
  typeSchemas: OperationSchemas;
125
+ operation: Operation;
153
126
  paramsCasing: PluginVueQuery['resolvedOptions']['paramsCasing'];
154
- paramsType: PluginVueQuery['resolvedOptions']['paramsType'];
155
127
  pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
156
- dataReturnType: PluginVueQuery['resolvedOptions']['client']['dataReturnType'];
157
- initialPageParam: Infinite['initialPageParam'];
158
- cursorParam: Infinite['cursorParam'];
159
- queryParam: Infinite['queryParam'];
128
+ transformer: Transformer | undefined;
160
129
  };
161
- type GetParamsProps$2 = {
162
- paramsCasing: PluginVueQuery['resolvedOptions']['paramsCasing'];
163
- paramsType: PluginVueQuery['resolvedOptions']['paramsType'];
130
+ type GetParamsProps$3 = {
164
131
  pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
165
132
  typeSchemas: OperationSchemas;
166
133
  };
167
- declare function InfiniteQueryOptions({
134
+ declare function MutationKey({
168
135
  name,
169
- clientName,
170
- initialPageParam,
171
- cursorParam,
172
136
  typeSchemas,
173
- paramsType,
174
137
  paramsCasing,
175
- dataReturnType,
176
138
  pathParamsType,
177
- queryParam,
178
- queryKeyName
179
- }: Props$2): KubbNode;
180
- declare namespace InfiniteQueryOptions {
181
- var getParams: ({
182
- paramsType,
183
- paramsCasing,
184
- pathParamsType,
185
- typeSchemas
186
- }: GetParamsProps$2) => FunctionParams;
139
+ operation,
140
+ typeName,
141
+ transformer
142
+ }: Props$3): KubbNode;
143
+ declare namespace MutationKey {
144
+ var getParams: ({}: GetParamsProps$3) => FunctionParams;
145
+ var getTransformer: Transformer;
187
146
  }
188
147
  //#endregion
189
- //#region src/components/InfiniteQuery.d.ts
190
- type Props$1 = {
148
+ //#region src/components/Query.d.ts
149
+ type Props$2 = {
191
150
  /**
192
151
  * Name of the function
193
152
  */
@@ -202,37 +161,37 @@ type Props$1 = {
202
161
  pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
203
162
  dataReturnType: PluginVueQuery['resolvedOptions']['client']['dataReturnType'];
204
163
  };
205
- type GetParamsProps$1 = {
164
+ type GetParamsProps$2 = {
206
165
  paramsCasing: PluginVueQuery['resolvedOptions']['paramsCasing'];
207
166
  paramsType: PluginVueQuery['resolvedOptions']['paramsType'];
208
167
  pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
209
168
  dataReturnType: PluginVueQuery['resolvedOptions']['client']['dataReturnType'];
210
169
  typeSchemas: OperationSchemas;
211
170
  };
212
- declare function InfiniteQuery({
171
+ declare function Query({
213
172
  name,
214
173
  queryKeyTypeName,
215
174
  queryOptionsName,
216
175
  queryKeyName,
217
176
  paramsType,
218
- pathParamsType,
219
177
  paramsCasing,
178
+ pathParamsType,
220
179
  dataReturnType,
221
180
  typeSchemas,
222
181
  operation
223
- }: Props$1): KubbNode;
224
- declare namespace InfiniteQuery {
182
+ }: Props$2): KubbNode;
183
+ declare namespace Query {
225
184
  var getParams: ({
226
- paramsType,
227
185
  paramsCasing,
186
+ paramsType,
228
187
  pathParamsType,
229
188
  dataReturnType,
230
189
  typeSchemas
231
- }: GetParamsProps$1) => FunctionParams;
190
+ }: GetParamsProps$2) => FunctionParams;
232
191
  }
233
192
  //#endregion
234
- //#region src/components/MutationKey.d.ts
235
- type Props = {
193
+ //#region src/components/QueryKey.d.ts
194
+ type Props$1 = {
236
195
  name: string;
237
196
  typeName: string;
238
197
  typeSchemas: OperationSchemas;
@@ -241,11 +200,12 @@ type Props = {
241
200
  pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
242
201
  transformer: Transformer | undefined;
243
202
  };
244
- type GetParamsProps = {
203
+ type GetParamsProps$1 = {
204
+ paramsCasing: PluginVueQuery['resolvedOptions']['paramsCasing'];
245
205
  pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
246
206
  typeSchemas: OperationSchemas;
247
207
  };
248
- declare function MutationKey({
208
+ declare function QueryKey({
249
209
  name,
250
210
  typeSchemas,
251
211
  paramsCasing,
@@ -253,11 +213,51 @@ declare function MutationKey({
253
213
  operation,
254
214
  typeName,
255
215
  transformer
256
- }: Props): KubbNode;
257
- declare namespace MutationKey {
258
- var getParams: ({}: GetParamsProps) => FunctionParams;
216
+ }: Props$1): KubbNode;
217
+ declare namespace QueryKey {
218
+ var getParams: ({
219
+ pathParamsType,
220
+ paramsCasing,
221
+ typeSchemas
222
+ }: GetParamsProps$1) => FunctionParams;
259
223
  var getTransformer: Transformer;
260
224
  }
261
225
  //#endregion
226
+ //#region src/components/QueryOptions.d.ts
227
+ type Props = {
228
+ name: string;
229
+ clientName: string;
230
+ queryKeyName: string;
231
+ typeSchemas: OperationSchemas;
232
+ paramsCasing: PluginVueQuery['resolvedOptions']['paramsCasing'];
233
+ paramsType: PluginVueQuery['resolvedOptions']['paramsType'];
234
+ pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
235
+ dataReturnType: PluginVueQuery['resolvedOptions']['client']['dataReturnType'];
236
+ };
237
+ type GetParamsProps = {
238
+ paramsCasing: PluginVueQuery['resolvedOptions']['paramsCasing'];
239
+ paramsType: PluginVueQuery['resolvedOptions']['paramsType'];
240
+ pathParamsType: PluginVueQuery['resolvedOptions']['pathParamsType'];
241
+ typeSchemas: OperationSchemas;
242
+ };
243
+ declare function QueryOptions({
244
+ name,
245
+ clientName,
246
+ dataReturnType,
247
+ typeSchemas,
248
+ paramsCasing,
249
+ paramsType,
250
+ pathParamsType,
251
+ queryKeyName
252
+ }: Props): KubbNode;
253
+ declare namespace QueryOptions {
254
+ var getParams: ({
255
+ paramsType,
256
+ paramsCasing,
257
+ pathParamsType,
258
+ typeSchemas
259
+ }: GetParamsProps) => FunctionParams;
260
+ }
261
+ //#endregion
262
262
  export { InfiniteQuery, InfiniteQueryOptions, Mutation, MutationKey, Query, QueryKey, QueryOptions };
263
263
  //# sourceMappingURL=components.d.ts.map
@@ -1,3 +1,3 @@
1
- import { a as QueryKey, i as QueryOptions, n as InfiniteQueryOptions, o as Mutation, r as Query, s as MutationKey, t as InfiniteQuery } from "./components-B8p5782n.js";
1
+ import { a as InfiniteQuery, i as InfiniteQueryOptions, n as Mutation, o as QueryOptions, r as MutationKey, s as QueryKey, t as Query } from "./components-kADKAHgd.js";
2
2
 
3
3
  export { InfiniteQuery, InfiniteQueryOptions, Mutation, MutationKey, Query, QueryKey, QueryOptions };