@kubb/plugin-vue-query 5.0.0-beta.31 → 5.0.0-beta.33

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 (2) hide show
  1. package/extension.yaml +4 -29
  2. package/package.json +8 -8
package/extension.yaml CHANGED
@@ -317,31 +317,6 @@ options:
317
317
  }),
318
318
  ],
319
319
  })
320
- - name: contentType
321
- type: "'application/json' | (string & {})"
322
- required: false
323
- description: |
324
- Selects which request/response media type the generator reads from the OpenAPI spec.
325
-
326
- When omitted, Kubb picks the first JSON-compatible media type it finds (`application/json`, `application/vnd.api+json`, anything ending in `+json`). Set this when your spec defines multiple media types for the same operation and you want a non-default one.
327
- examples:
328
- - name: JSON API media type
329
- files:
330
- - lang: typescript
331
- twoslash: false
332
- code: |
333
- import { defineConfig } from 'kubb'
334
- import { pluginTs } from '@kubb/plugin-ts'
335
-
336
- export default defineConfig({
337
- input: { path: './petStore.yaml' },
338
- output: { path: './src/gen' },
339
- plugins: [
340
- pluginTs({
341
- contentType: 'application/vnd.api+json',
342
- }),
343
- ],
344
- })
345
320
  - name: group
346
321
  type: Group
347
322
  required: false
@@ -1002,13 +977,13 @@ options:
1002
977
  - name: methods
1003
978
  type: Array<HttpMethod>
1004
979
  required: false
1005
- default: "['post', 'put', 'delete']"
980
+ default: "['post', 'put', 'patch', 'delete']"
1006
981
  description: |
1007
982
  HTTP methods treated as mutations. Operations using one of these methods generate a `useMutation`-style hook instead of a query.
1008
983
 
1009
- Defaults to `['post', 'put', 'delete']`. Add `'patch'` if your API uses it for partial updates.
984
+ Defaults to `['post', 'put', 'patch', 'delete']`. Narrow the list if your API uses one of these methods for reads.
1010
985
  examples:
1011
- - name: Include PATCH as a mutation
986
+ - name: Treat only POST and PUT as mutations
1012
987
  files:
1013
988
  - lang: typescript
1014
989
  twoslash: false
@@ -1021,7 +996,7 @@ options:
1021
996
  output: { path: './src/gen' },
1022
997
  plugins: [
1023
998
  pluginReactQuery({
1024
- mutation: { methods: ['post', 'put', 'patch', 'delete'] },
999
+ mutation: { methods: ['post', 'put'] },
1025
1000
  }),
1026
1001
  ],
1027
1002
  })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kubb/plugin-vue-query",
3
- "version": "5.0.0-beta.31",
3
+ "version": "5.0.0-beta.33",
4
4
  "description": "Generate type-safe TanStack Query (Vue Query) composables from your OpenAPI specification. Covers useQuery, useMutation, useInfiniteQuery, and queryOptions with Vue 3 Composition API support.",
5
5
  "keywords": [
6
6
  "code-generation",
@@ -70,12 +70,12 @@
70
70
  "registry": "https://registry.npmjs.org/"
71
71
  },
72
72
  "dependencies": {
73
- "@kubb/core": "5.0.0-beta.31",
74
- "@kubb/renderer-jsx": "5.0.0-beta.31",
75
- "remeda": "^2.34.1",
76
- "@kubb/plugin-client": "5.0.0-beta.31",
77
- "@kubb/plugin-ts": "5.0.0-beta.31",
78
- "@kubb/plugin-zod": "5.0.0-beta.31"
73
+ "@kubb/core": "5.0.0-beta.33",
74
+ "@kubb/renderer-jsx": "5.0.0-beta.33",
75
+ "remeda": "^2.36.0",
76
+ "@kubb/plugin-client": "5.0.0-beta.33",
77
+ "@kubb/plugin-ts": "5.0.0-beta.33",
78
+ "@kubb/plugin-zod": "5.0.0-beta.33"
79
79
  },
80
80
  "devDependencies": {
81
81
  "@internals/shared": "0.0.0",
@@ -83,7 +83,7 @@
83
83
  "@internals/utils": "0.0.0"
84
84
  },
85
85
  "peerDependencies": {
86
- "@kubb/renderer-jsx": "5.0.0-beta.31"
86
+ "@kubb/renderer-jsx": "5.0.0-beta.33"
87
87
  },
88
88
  "size-limit": [
89
89
  {