@kubb/plugin-vue-query 5.13.0-canary.20261122T213936 → 5.13.1
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/dist/index.cjs +332 -280
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +334 -282
- package/dist/index.js.map +1 -1
- package/docs/options.md +11 -0
- package/package.json +11 -11
package/docs/options.md
CHANGED
|
@@ -155,6 +155,17 @@ import { queryKeyTransformer } from '@kubb/plugin-vue-query'
|
|
|
155
155
|
queryKey: (props) => [JSON.stringify('v2'), ...queryKeyTransformer(props)]
|
|
156
156
|
```
|
|
157
157
|
|
|
158
|
+
The generated helper also accepts optional `headers` for operations with header parameters. To include them in the cache key, reference the `headers` binding:
|
|
159
|
+
|
|
160
|
+
```typescript
|
|
161
|
+
queryKey: (props) => [
|
|
162
|
+
...queryKeyTransformer(props),
|
|
163
|
+
...(props.node.parameters?.some((param) => param.in === 'header') ? ['...(headers ? [headers] : [])'] : []),
|
|
164
|
+
]
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
Headers stay out of the default key. Include only response-varying values that are safe to store in caches and devtools.
|
|
168
|
+
|
|
158
169
|
### mutation
|
|
159
170
|
|
|
160
171
|
Which operations become mutations and where TanStack Query is imported from. `false` skips mutation output.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kubb/plugin-vue-query",
|
|
3
|
-
"version": "5.13.
|
|
3
|
+
"version": "5.13.1",
|
|
4
4
|
"description": "Generate type-safe TanStack Query (Vue Query) composables with Kubb. Covers useQuery, useMutation, useInfiniteQuery, and queryOptions with Vue 3 Composition API support.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"code-generation",
|
|
@@ -83,18 +83,18 @@
|
|
|
83
83
|
"registry": "https://registry.npmjs.org/"
|
|
84
84
|
},
|
|
85
85
|
"dependencies": {
|
|
86
|
-
"@kubb/ast": "^5.
|
|
87
|
-
"@kubb/kit": "^5.
|
|
88
|
-
"@kubb/plugin-ts": "^5.7.0
|
|
89
|
-
"@kubb/renderer-jsx": "^5.
|
|
86
|
+
"@kubb/ast": "^5.24.0",
|
|
87
|
+
"@kubb/kit": "^5.24.0",
|
|
88
|
+
"@kubb/plugin-ts": "^5.7.0",
|
|
89
|
+
"@kubb/renderer-jsx": "^5.24.0"
|
|
90
90
|
},
|
|
91
91
|
"devDependencies": {
|
|
92
|
-
"@internals/ast": "0.
|
|
93
|
-
"@internals/client": "0.
|
|
94
|
-
"@internals/shared": "0.
|
|
95
|
-
"@internals/tanstack-query": "0.
|
|
96
|
-
"@internals/utils": "0.
|
|
97
|
-
"@kubb/plugin-client": "6.5.0
|
|
92
|
+
"@internals/ast": "0.0.0",
|
|
93
|
+
"@internals/client": "0.0.0",
|
|
94
|
+
"@internals/shared": "0.0.0",
|
|
95
|
+
"@internals/tanstack-query": "0.0.0",
|
|
96
|
+
"@internals/utils": "0.0.0",
|
|
97
|
+
"@kubb/plugin-client": "6.5.0",
|
|
98
98
|
"@tanstack/vue-query": "^5.108.1",
|
|
99
99
|
"vue": "^3.5.45"
|
|
100
100
|
},
|