@kubb/plugin-vue-query 4.29.0 → 4.31.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.
- package/dist/generators.cjs +1 -1
- package/dist/generators.js +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/{queryGenerator-gk8pNl_4.js → queryGenerator-Da1vIMnD.js} +7 -7
- package/dist/queryGenerator-Da1vIMnD.js.map +1 -0
- package/dist/{queryGenerator-e6WGv0jo.cjs → queryGenerator-Y2_A3T-a.cjs} +7 -7
- package/dist/queryGenerator-Y2_A3T-a.cjs.map +1 -0
- package/package.json +11 -10
- package/src/generators/infiniteQueryGenerator.tsx +4 -2
- package/src/generators/mutationGenerator.tsx +4 -2
- package/src/generators/queryGenerator.tsx +4 -2
- package/dist/queryGenerator-e6WGv0jo.cjs.map +0 -1
- package/dist/queryGenerator-gk8pNl_4.js.map +0 -1
- package/src/generators/__snapshots__/clientDataReturnTypeFull.ts +0 -102
- package/src/generators/__snapshots__/clientGetImportPath.ts +0 -91
- package/src/generators/__snapshots__/clientPostImportPath.ts +0 -77
- package/src/generators/__snapshots__/findByTags.ts +0 -91
- package/src/generators/__snapshots__/findByTagsObject.ts +0 -88
- package/src/generators/__snapshots__/findByTagsPathParamsObject.ts +0 -91
- package/src/generators/__snapshots__/findByTagsTemplateString.ts +0 -92
- package/src/generators/__snapshots__/findByTagsWithCustomQueryKey.ts +0 -91
- package/src/generators/__snapshots__/findByTagsWithZod.ts +0 -91
- package/src/generators/__snapshots__/findInfiniteByTags.ts +0 -105
- package/src/generators/__snapshots__/findInfiniteByTagsCursor.ts +0 -105
- package/src/generators/__snapshots__/postAsQuery.ts +0 -104
- package/src/generators/__snapshots__/updatePetById.ts +0 -77
- package/src/generators/__snapshots__/updatePetByIdPathParamsObject.ts +0 -77
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"queryGenerator-gk8pNl_4.js","names":[],"sources":["../src/generators/infiniteQueryGenerator.tsx","../src/generators/mutationGenerator.tsx","../src/generators/queryGenerator.tsx"],"sourcesContent":["import path from 'node:path'\nimport { usePluginManager } from '@kubb/core/hooks'\nimport { pluginClientName } from '@kubb/plugin-client'\nimport { Client } from '@kubb/plugin-client/components'\nimport { createReactGenerator } from '@kubb/plugin-oas/generators'\nimport { useOas, useOperationManager } from '@kubb/plugin-oas/hooks'\nimport { getBanner, getFooter } from '@kubb/plugin-oas/utils'\nimport { pluginTsName } from '@kubb/plugin-ts'\nimport { pluginZodName } from '@kubb/plugin-zod'\nimport { File } from '@kubb/react-fabric'\nimport { difference } from 'remeda'\nimport { InfiniteQuery, InfiniteQueryOptions, QueryKey } from '../components'\nimport type { PluginVueQuery } from '../types'\n\nexport const infiniteQueryGenerator = createReactGenerator<PluginVueQuery>({\n name: 'vue-infinite-query',\n Operation({ config, operation, generator, plugin }) {\n const {\n options,\n options: { output },\n } = plugin\n const pluginManager = usePluginManager()\n\n const oas = useOas()\n const { getSchemas, getName, getFile } = useOperationManager(generator)\n\n const isQuery = typeof options.query === 'boolean' ? true : options.query?.methods.some((method) => operation.method === method)\n const isMutation = difference(options.mutation ? options.mutation.methods : [], options.query ? options.query.methods : []).some(\n (method) => operation.method === method,\n )\n const isInfinite = isQuery && !!options.infinite\n const importPath = options.query ? options.query.importPath : '@tanstack/vue-query'\n\n const query = {\n name: getName(operation, {\n type: 'function',\n prefix: 'use',\n suffix: 'infinite',\n }),\n typeName: getName(operation, { type: 'type' }),\n file: getFile(operation, { prefix: 'use', suffix: 'infinite' }),\n }\n\n const hasClientPlugin = !!pluginManager.getPluginByKey([pluginClientName])\n // Class-based clients are not compatible with query hooks, so we generate inline clients\n const shouldUseClientPlugin = hasClientPlugin && options.client.clientType !== 'class'\n const client = {\n name: shouldUseClientPlugin\n ? getName(operation, {\n type: 'function',\n pluginKey: [pluginClientName],\n })\n : getName(operation, {\n type: 'function',\n suffix: 'infinite',\n }),\n file: getFile(operation, { pluginKey: [pluginClientName] }),\n }\n\n const queryOptions = {\n name: getName(operation, {\n type: 'function',\n suffix: 'InfiniteQueryOptions',\n }),\n }\n\n const queryKey = {\n name: getName(operation, { type: 'const', suffix: 'InfiniteQueryKey' }),\n typeName: getName(operation, {\n type: 'type',\n suffix: 'InfiniteQueryKey',\n }),\n }\n\n const type = {\n file: getFile(operation, { pluginKey: [pluginTsName] }),\n //todo remove type?\n schemas: getSchemas(operation, {\n pluginKey: [pluginTsName],\n type: 'type',\n }),\n }\n\n const zod = {\n file: getFile(operation, { pluginKey: [pluginZodName] }),\n schemas: getSchemas(operation, {\n pluginKey: [pluginZodName],\n type: 'function',\n }),\n }\n\n if (!isQuery || isMutation || !isInfinite) {\n return null\n }\n\n return (\n <File\n baseName={query.file.baseName}\n path={query.file.path}\n meta={query.file.meta}\n banner={getBanner({ oas, output, config: pluginManager.config })}\n footer={getFooter({ oas, output })}\n >\n {options.parser === 'zod' && (\n <File.Import name={[zod.schemas.response.name, zod.schemas.request?.name].filter(Boolean)} root={query.file.path} path={zod.file.path} />\n )}\n {options.client.importPath ? (\n <>\n <File.Import name={'fetch'} path={options.client.importPath} />\n <File.Import name={['Client', 'RequestConfig', 'ResponseErrorConfig']} path={options.client.importPath} isTypeOnly />\n {options.client.dataReturnType === 'full' && <File.Import name={['ResponseConfig']} path={options.client.importPath} isTypeOnly />}\n </>\n ) : (\n <>\n <File.Import name={['fetch']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')} />\n <File.Import\n name={['Client', 'RequestConfig', 'ResponseErrorConfig']}\n root={query.file.path}\n path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')}\n isTypeOnly\n />\n {options.client.dataReturnType === 'full' && (\n <File.Import name={['ResponseConfig']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')} isTypeOnly />\n )}\n </>\n )}\n <File.Import name={['toValue']} path=\"vue\" />\n <File.Import name={['MaybeRefOrGetter']} path=\"vue\" isTypeOnly />\n {shouldUseClientPlugin && <File.Import name={[client.name]} root={query.file.path} path={client.file.path} />}\n {!shouldUseClientPlugin && (\n <File.Import name={['buildFormData']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/config.ts')} />\n )}\n <File.Import\n name={[\n type.schemas.request?.name,\n type.schemas.response.name,\n type.schemas.pathParams?.name,\n type.schemas.queryParams?.name,\n type.schemas.headerParams?.name,\n ...(type.schemas.statusCodes?.map((item) => item.name) || []),\n ].filter(Boolean)}\n root={query.file.path}\n path={type.file.path}\n isTypeOnly\n />\n <QueryKey\n name={queryKey.name}\n typeName={queryKey.typeName}\n operation={operation}\n paramsCasing={options.paramsCasing}\n pathParamsType={options.pathParamsType}\n typeSchemas={type.schemas}\n transformer={options.queryKey}\n />\n {!shouldUseClientPlugin && (\n <Client\n name={client.name}\n baseURL={options.client.baseURL}\n operation={operation}\n typeSchemas={type.schemas}\n zodSchemas={zod.schemas}\n dataReturnType={options.client.dataReturnType || 'data'}\n paramsCasing={options.client?.paramsCasing || options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n parser={options.parser}\n />\n )}\n {options.infinite && (\n <>\n <File.Import name={['InfiniteData']} isTypeOnly path={importPath} />\n <File.Import name={['infiniteQueryOptions']} path={importPath} />\n <InfiniteQueryOptions\n name={queryOptions.name}\n clientName={client.name}\n queryKeyName={queryKey.name}\n typeSchemas={type.schemas}\n paramsType={options.paramsType}\n paramsCasing={options.paramsCasing}\n pathParamsType={options.pathParamsType}\n dataReturnType={options.client.dataReturnType || 'data'}\n cursorParam={options.infinite.cursorParam}\n nextParam={options.infinite.nextParam}\n previousParam={options.infinite.previousParam}\n initialPageParam={options.infinite.initialPageParam}\n queryParam={options.infinite.queryParam}\n />\n </>\n )}\n {options.infinite && (\n <>\n <File.Import name={['useInfiniteQuery']} path={importPath} />\n <File.Import name={['QueryKey', 'QueryClient', 'UseInfiniteQueryOptions', 'UseInfiniteQueryReturnType']} path={importPath} isTypeOnly />\n <InfiniteQuery\n name={query.name}\n queryOptionsName={queryOptions.name}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n operation={operation}\n dataReturnType={options.client.dataReturnType || 'data'}\n queryKeyName={queryKey.name}\n queryKeyTypeName={queryKey.typeName}\n />\n </>\n )}\n </File>\n )\n },\n})\n","import path from 'node:path'\nimport { usePluginManager } from '@kubb/core/hooks'\nimport { pluginClientName } from '@kubb/plugin-client'\nimport { Client } from '@kubb/plugin-client/components'\nimport { createReactGenerator } from '@kubb/plugin-oas/generators'\nimport { useOas, useOperationManager } from '@kubb/plugin-oas/hooks'\nimport { getBanner, getFooter } from '@kubb/plugin-oas/utils'\nimport { pluginTsName } from '@kubb/plugin-ts'\nimport { pluginZodName } from '@kubb/plugin-zod'\nimport { File } from '@kubb/react-fabric'\nimport { difference } from 'remeda'\nimport { Mutation, MutationKey } from '../components'\nimport type { PluginVueQuery } from '../types'\n\nexport const mutationGenerator = createReactGenerator<PluginVueQuery>({\n name: 'vue-query',\n Operation({ config, operation, generator, plugin }) {\n const {\n options,\n options: { output },\n } = plugin\n const pluginManager = usePluginManager()\n\n const oas = useOas()\n const { getSchemas, getName, getFile } = useOperationManager(generator)\n\n const isQuery = !!options.query && options.query?.methods.some((method) => operation.method === method)\n const isMutation =\n options.mutation !== false &&\n !isQuery &&\n difference(options.mutation ? options.mutation.methods : [], options.query ? options.query.methods : []).some((method) => operation.method === method)\n\n const importPath = options.mutation ? options.mutation.importPath : '@tanstack/vue-query'\n\n const mutation = {\n name: getName(operation, { type: 'function', prefix: 'use' }),\n typeName: getName(operation, { type: 'type' }),\n file: getFile(operation, { prefix: 'use' }),\n }\n\n const type = {\n file: getFile(operation, { pluginKey: [pluginTsName] }),\n //todo remove type?\n schemas: getSchemas(operation, { pluginKey: [pluginTsName], type: 'type' }),\n }\n\n const zod = {\n file: getFile(operation, { pluginKey: [pluginZodName] }),\n schemas: getSchemas(operation, { pluginKey: [pluginZodName], type: 'function' }),\n }\n\n const hasClientPlugin = !!pluginManager.getPluginByKey([pluginClientName])\n // Class-based clients are not compatible with query hooks, so we generate inline clients\n const shouldUseClientPlugin = hasClientPlugin && options.client.clientType !== 'class'\n const client = {\n name: shouldUseClientPlugin\n ? getName(operation, {\n type: 'function',\n pluginKey: [pluginClientName],\n })\n : getName(operation, {\n type: 'function',\n }),\n file: getFile(operation, { pluginKey: [pluginClientName] }),\n }\n\n const mutationKey = {\n name: getName(operation, { type: 'const', suffix: 'MutationKey' }),\n typeName: getName(operation, { type: 'type', suffix: 'MutationKey' }),\n }\n\n if (!isMutation) {\n return null\n }\n\n return (\n <File\n baseName={mutation.file.baseName}\n path={mutation.file.path}\n meta={mutation.file.meta}\n banner={getBanner({ oas, output, config: pluginManager.config })}\n footer={getFooter({ oas, output })}\n >\n {options.parser === 'zod' && (\n <File.Import name={[zod.schemas.response.name, zod.schemas.request?.name].filter(Boolean)} root={mutation.file.path} path={zod.file.path} />\n )}\n {options.client.importPath ? (\n <>\n <File.Import name={'fetch'} path={options.client.importPath} />\n <File.Import name={['Client', 'RequestConfig', 'ResponseErrorConfig']} path={options.client.importPath} isTypeOnly />\n {options.client.dataReturnType === 'full' && <File.Import name={['ResponseConfig']} path={options.client.importPath} isTypeOnly />}\n </>\n ) : (\n <>\n <File.Import name={['fetch']} root={mutation.file.path} path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')} />\n <File.Import\n name={['Client', 'RequestConfig', 'ResponseErrorConfig']}\n root={mutation.file.path}\n path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')}\n isTypeOnly\n />\n {options.client.dataReturnType === 'full' && (\n <File.Import\n name={['ResponseConfig']}\n root={mutation.file.path}\n path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')}\n isTypeOnly\n />\n )}\n </>\n )}\n <File.Import name={['MaybeRefOrGetter']} path=\"vue\" isTypeOnly />\n {shouldUseClientPlugin && <File.Import name={[client.name]} root={mutation.file.path} path={client.file.path} />}\n {!shouldUseClientPlugin && (\n <File.Import name={['buildFormData']} root={mutation.file.path} path={path.resolve(config.root, config.output.path, '.kubb/config.ts')} />\n )}\n <File.Import\n name={[\n type.schemas.request?.name,\n type.schemas.response.name,\n type.schemas.pathParams?.name,\n type.schemas.queryParams?.name,\n type.schemas.headerParams?.name,\n ...(type.schemas.statusCodes?.map((item) => item.name) || []),\n ].filter(Boolean)}\n root={mutation.file.path}\n path={type.file.path}\n isTypeOnly\n />\n <MutationKey\n name={mutationKey.name}\n typeName={mutationKey.typeName}\n operation={operation}\n pathParamsType={options.pathParamsType}\n paramsCasing={options.paramsCasing}\n typeSchemas={type.schemas}\n transformer={options.mutationKey}\n />\n {!shouldUseClientPlugin && (\n <Client\n name={client.name}\n baseURL={options.client.baseURL}\n operation={operation}\n typeSchemas={type.schemas}\n zodSchemas={zod.schemas}\n dataReturnType={options.client.dataReturnType || 'data'}\n paramsCasing={options.client?.paramsCasing || options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n parser={options.parser}\n />\n )}\n {options.mutation && (\n <>\n <File.Import name={['useMutation']} path={importPath} />\n <File.Import name={['MutationObserverOptions', 'QueryClient']} path={importPath} isTypeOnly />\n <Mutation\n name={mutation.name}\n clientName={client.name}\n typeName={mutation.typeName}\n typeSchemas={type.schemas}\n operation={operation}\n paramsCasing={options.paramsCasing}\n dataReturnType={options.client.dataReturnType || 'data'}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n mutationKeyName={mutationKey.name}\n />\n </>\n )}\n </File>\n )\n },\n})\n","import path from 'node:path'\nimport { usePluginManager } from '@kubb/core/hooks'\nimport { pluginClientName } from '@kubb/plugin-client'\nimport { Client } from '@kubb/plugin-client/components'\nimport { createReactGenerator } from '@kubb/plugin-oas/generators'\nimport { useOas, useOperationManager } from '@kubb/plugin-oas/hooks'\nimport { getBanner, getFooter } from '@kubb/plugin-oas/utils'\nimport { pluginTsName } from '@kubb/plugin-ts'\nimport { pluginZodName } from '@kubb/plugin-zod'\nimport { File } from '@kubb/react-fabric'\nimport { difference } from 'remeda'\nimport { Query, QueryKey, QueryOptions } from '../components'\nimport type { PluginVueQuery } from '../types'\n\nexport const queryGenerator = createReactGenerator<PluginVueQuery>({\n name: 'vue-query',\n Operation({ config, operation, generator, plugin }) {\n const {\n options,\n options: { output },\n } = plugin\n const pluginManager = usePluginManager()\n\n const oas = useOas()\n const { getSchemas, getName, getFile } = useOperationManager(generator)\n\n const isQuery = typeof options.query === 'boolean' ? true : options.query?.methods.some((method) => operation.method === method)\n const isMutation = difference(options.mutation ? options.mutation.methods : [], options.query ? options.query.methods : []).some(\n (method) => operation.method === method,\n )\n const importPath = options.query ? options.query.importPath : '@tanstack/vue-query'\n\n const query = {\n name: getName(operation, { type: 'function', prefix: 'use' }),\n typeName: getName(operation, { type: 'type' }),\n file: getFile(operation, { prefix: 'use' }),\n }\n\n const hasClientPlugin = !!pluginManager.getPluginByKey([pluginClientName])\n // Class-based clients are not compatible with query hooks, so we generate inline clients\n const shouldUseClientPlugin = hasClientPlugin && options.client.clientType !== 'class'\n const client = {\n name: shouldUseClientPlugin\n ? getName(operation, {\n type: 'function',\n pluginKey: [pluginClientName],\n })\n : getName(operation, {\n type: 'function',\n }),\n file: getFile(operation, { pluginKey: [pluginClientName] }),\n }\n\n const queryOptions = {\n name: getName(operation, { type: 'function', suffix: 'QueryOptions' }),\n }\n\n const queryKey = {\n name: getName(operation, { type: 'const', suffix: 'QueryKey' }),\n typeName: getName(operation, { type: 'type', suffix: 'QueryKey' }),\n }\n\n const type = {\n file: getFile(operation, { pluginKey: [pluginTsName] }),\n //todo remove type?\n schemas: getSchemas(operation, {\n pluginKey: [pluginTsName],\n type: 'type',\n }),\n }\n\n const zod = {\n file: getFile(operation, { pluginKey: [pluginZodName] }),\n schemas: getSchemas(operation, {\n pluginKey: [pluginZodName],\n type: 'function',\n }),\n }\n\n if (!isQuery || isMutation) {\n return null\n }\n\n return (\n <File\n baseName={query.file.baseName}\n path={query.file.path}\n meta={query.file.meta}\n banner={getBanner({ oas, output, config: pluginManager.config })}\n footer={getFooter({ oas, output })}\n >\n {options.parser === 'zod' && (\n <File.Import name={[zod.schemas.response.name, zod.schemas.request?.name].filter(Boolean)} root={query.file.path} path={zod.file.path} />\n )}\n {options.client.importPath ? (\n <>\n <File.Import name={'fetch'} path={options.client.importPath} />\n <File.Import name={['Client', 'RequestConfig', 'ResponseErrorConfig']} path={options.client.importPath} isTypeOnly />\n {options.client.dataReturnType === 'full' && <File.Import name={['ResponseConfig']} path={options.client.importPath} isTypeOnly />}\n </>\n ) : (\n <>\n <File.Import name={['fetch']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')} />\n <File.Import\n name={['Client', 'RequestConfig', 'ResponseErrorConfig']}\n root={query.file.path}\n path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')}\n isTypeOnly\n />\n {options.client.dataReturnType === 'full' && (\n <File.Import name={['ResponseConfig']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/fetch.ts')} isTypeOnly />\n )}\n </>\n )}\n <File.Import name={['toValue']} path=\"vue\" />\n <File.Import name={['MaybeRefOrGetter']} path=\"vue\" isTypeOnly />\n {shouldUseClientPlugin && <File.Import name={[client.name]} root={query.file.path} path={client.file.path} />}\n {!shouldUseClientPlugin && (\n <File.Import name={['buildFormData']} root={query.file.path} path={path.resolve(config.root, config.output.path, '.kubb/config.ts')} />\n )}\n <File.Import\n name={[\n type.schemas.request?.name,\n type.schemas.response.name,\n type.schemas.pathParams?.name,\n type.schemas.queryParams?.name,\n type.schemas.headerParams?.name,\n ...(type.schemas.statusCodes?.map((item) => item.name) || []),\n ].filter(Boolean)}\n root={query.file.path}\n path={type.file.path}\n isTypeOnly\n />\n <QueryKey\n name={queryKey.name}\n typeName={queryKey.typeName}\n operation={operation}\n paramsCasing={options.paramsCasing}\n pathParamsType={options.pathParamsType}\n typeSchemas={type.schemas}\n transformer={options.queryKey}\n />\n {!shouldUseClientPlugin && (\n <Client\n name={client.name}\n baseURL={options.client.baseURL}\n operation={operation}\n typeSchemas={type.schemas}\n zodSchemas={zod.schemas}\n dataReturnType={options.client.dataReturnType || 'data'}\n paramsCasing={options.client?.paramsCasing || options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n parser={options.parser}\n />\n )}\n <File.Import name={['queryOptions']} path={importPath} />\n <QueryOptions\n name={queryOptions.name}\n clientName={client.name}\n queryKeyName={queryKey.name}\n paramsCasing={options.paramsCasing}\n typeSchemas={type.schemas}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n dataReturnType={options.client.dataReturnType || 'data'}\n />\n {options.query && (\n <>\n <File.Import name={['useQuery']} path={importPath} />\n <File.Import name={['QueryKey', 'QueryClient', 'UseQueryOptions', 'UseQueryReturnType']} path={importPath} isTypeOnly />\n <Query\n name={query.name}\n queryOptionsName={queryOptions.name}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n operation={operation}\n dataReturnType={options.client.dataReturnType || 'data'}\n queryKeyName={queryKey.name}\n queryKeyTypeName={queryKey.typeName}\n />\n </>\n )}\n </File>\n )\n },\n})\n"],"mappings":";;;;;;;;;;;;;;;;AAcA,MAAa,yBAAyB,qBAAqC;CACzE,MAAM;CACN,UAAU,EAAE,QAAQ,WAAW,WAAW,UAAU;EAClD,MAAM,EACJ,SACA,SAAS,EAAE,aACT;EACJ,MAAM,gBAAgB,kBAAkB;EAExC,MAAM,MAAM,QAAQ;EACpB,MAAM,EAAE,YAAY,SAAS,YAAY,oBAAoB,UAAU;EAEvE,MAAM,UAAU,OAAO,QAAQ,UAAU,YAAY,OAAO,QAAQ,OAAO,QAAQ,MAAM,WAAW,UAAU,WAAW,OAAO;EAChI,MAAM,aAAa,WAAW,QAAQ,WAAW,QAAQ,SAAS,UAAU,EAAE,EAAE,QAAQ,QAAQ,QAAQ,MAAM,UAAU,EAAE,CAAC,C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,YAAY,QAAQ;KACpB,gBAAgB,QAAQ;KACxB,QAAQ,QAAQ;MAChB;IAEJ,oBAAC,KAAK;KAAO,MAAM,CAAC,eAAe;KAAE,MAAM;MAAc;IACzD,oBAAC;KACC,MAAM,aAAa;KACnB,YAAY,OAAO;KACnB,cAAc,SAAS;KACvB,cAAc,QAAQ;KACtB,aAAa,KAAK;KAClB,YAAY,QAAQ;KACpB,gBAAgB,QAAQ;KACxB,gBAAgB,QAAQ,OAAO,kBAAkB;MACjD;IACD,QAAQ,SACP;KACE,oBAAC,KAAK;MAAO,MAAM,CAAC,WAAW;MAAE,MAAM;OAAc;KACrD,oBAAC,KAAK;MAAO,MAAM;OAAC;OAAY;OAAe;OAAmB;OAAqB;MAAE,MAAM;MAAY;OAAa;KACxH,oBAAC;MACC,MAAM,MAAM;MACZ,kBAAkB,aAAa;MAC/B,aAAa,KAAK;MAClB,cAAc,QAAQ;MACtB,YAAY,QAAQ;MACpB,gBAAgB,QAAQ;MACb;MACX,gBAAgB,QAAQ,OAAO,kBAAkB;MACjD,cAAc,SAAS;MACvB,kBAAkB,SAAS;OAC3B;QACD;;IAEA;;CAGZ,CAAC"}
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generated by Kubb (https://kubb.dev/).
|
|
3
|
-
* Do not edit manually.
|
|
4
|
-
*/
|
|
5
|
-
import type { Client, RequestConfig, ResponseErrorConfig, ResponseConfig } from './test/.kubb/fetch'
|
|
6
|
-
import type { QueryKey, QueryClient, UseQueryOptions, UseQueryReturnType } from '@tanstack/react-query'
|
|
7
|
-
import type { MaybeRefOrGetter } from 'vue'
|
|
8
|
-
import { fetch } from './test/.kubb/fetch'
|
|
9
|
-
import { queryOptions, useQuery } from '@tanstack/react-query'
|
|
10
|
-
import { toValue } from 'vue'
|
|
11
|
-
|
|
12
|
-
export const findPetsByTagsQueryKey = (params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>) =>
|
|
13
|
-
[{ url: '/pet/findByTags' }, ...(params ? [params] : [])] as const
|
|
14
|
-
|
|
15
|
-
export type FindPetsByTagsQueryKey = ReturnType<typeof findPetsByTagsQueryKey>
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* @description Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
|
19
|
-
* @summary Finds Pets by tags
|
|
20
|
-
* {@link /pet/findByTags}
|
|
21
|
-
*/
|
|
22
|
-
export async function findPetsByTags(
|
|
23
|
-
headers: FindPetsByTagsHeaderParams,
|
|
24
|
-
params?: FindPetsByTagsQueryParams,
|
|
25
|
-
config: Partial<RequestConfig> & { client?: Client } = {},
|
|
26
|
-
) {
|
|
27
|
-
const { client: request = fetch, ...requestConfig } = config
|
|
28
|
-
|
|
29
|
-
const res = await request<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, unknown>({
|
|
30
|
-
method: 'GET',
|
|
31
|
-
url: `/pet/findByTags`,
|
|
32
|
-
params,
|
|
33
|
-
...requestConfig,
|
|
34
|
-
headers: { ...headers, ...requestConfig.headers },
|
|
35
|
-
})
|
|
36
|
-
return { ...res, data: findPetsByTagsQueryResponse.parse(res.data) }
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
export function findPetsByTagsQueryOptions(
|
|
40
|
-
headers: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
41
|
-
params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
42
|
-
config: Partial<RequestConfig> & { client?: Client } = {},
|
|
43
|
-
) {
|
|
44
|
-
const queryKey = findPetsByTagsQueryKey(params)
|
|
45
|
-
return queryOptions<
|
|
46
|
-
ResponseConfig<FindPetsByTagsQueryResponse>,
|
|
47
|
-
ResponseErrorConfig<FindPetsByTags400>,
|
|
48
|
-
ResponseConfig<FindPetsByTagsQueryResponse>,
|
|
49
|
-
typeof queryKey
|
|
50
|
-
>({
|
|
51
|
-
queryKey,
|
|
52
|
-
queryFn: async ({ signal }) => {
|
|
53
|
-
if (!config.signal) {
|
|
54
|
-
config.signal = signal
|
|
55
|
-
}
|
|
56
|
-
return findPetsByTags(toValue(headers), toValue(params), toValue(config))
|
|
57
|
-
},
|
|
58
|
-
})
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
/**
|
|
62
|
-
* @description Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
|
63
|
-
* @summary Finds Pets by tags
|
|
64
|
-
* {@link /pet/findByTags}
|
|
65
|
-
*/
|
|
66
|
-
export function useFindPetsByTags<
|
|
67
|
-
TData = ResponseConfig<FindPetsByTagsQueryResponse>,
|
|
68
|
-
TQueryData = ResponseConfig<FindPetsByTagsQueryResponse>,
|
|
69
|
-
TQueryKey extends QueryKey = FindPetsByTagsQueryKey,
|
|
70
|
-
>(
|
|
71
|
-
headers: MaybeRefOrGetter<FindPetsByTagsHeaderParams>,
|
|
72
|
-
params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
73
|
-
options: {
|
|
74
|
-
query?: Partial<UseQueryOptions<ResponseConfig<FindPetsByTagsQueryResponse>, ResponseErrorConfig<FindPetsByTags400>, TData, TQueryData, TQueryKey>> & {
|
|
75
|
-
client?: QueryClient
|
|
76
|
-
}
|
|
77
|
-
client?: Partial<RequestConfig> & { client?: Client }
|
|
78
|
-
} = {},
|
|
79
|
-
) {
|
|
80
|
-
const { query: queryConfig = {}, client: config = {} } = options ?? {}
|
|
81
|
-
const { client: queryClient, ...queryOptions } = queryConfig
|
|
82
|
-
const queryKey = (queryOptions && 'queryKey' in queryOptions ? toValue(queryOptions.queryKey) : undefined) ?? findPetsByTagsQueryKey(params)
|
|
83
|
-
|
|
84
|
-
const query = useQuery(
|
|
85
|
-
{
|
|
86
|
-
...findPetsByTagsQueryOptions(headers, params, config),
|
|
87
|
-
...queryOptions,
|
|
88
|
-
queryKey,
|
|
89
|
-
} as unknown as UseQueryOptions<
|
|
90
|
-
ResponseConfig<FindPetsByTagsQueryResponse>,
|
|
91
|
-
ResponseErrorConfig<FindPetsByTags400>,
|
|
92
|
-
TData,
|
|
93
|
-
ResponseConfig<FindPetsByTagsQueryResponse>,
|
|
94
|
-
TQueryKey
|
|
95
|
-
>,
|
|
96
|
-
toValue(queryClient),
|
|
97
|
-
) as UseQueryReturnType<TData, ResponseErrorConfig<FindPetsByTags400>> & { queryKey: TQueryKey }
|
|
98
|
-
|
|
99
|
-
query.queryKey = queryKey as TQueryKey
|
|
100
|
-
|
|
101
|
-
return query
|
|
102
|
-
}
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generated by Kubb (https://kubb.dev/).
|
|
3
|
-
* Do not edit manually.
|
|
4
|
-
*/
|
|
5
|
-
import fetch from 'axios'
|
|
6
|
-
import type { QueryKey, QueryClient, UseQueryOptions, UseQueryReturnType } from '@tanstack/react-query'
|
|
7
|
-
import type { Client, RequestConfig, ResponseErrorConfig } from 'axios'
|
|
8
|
-
import type { MaybeRefOrGetter } from 'vue'
|
|
9
|
-
import { queryOptions, useQuery } from '@tanstack/react-query'
|
|
10
|
-
import { toValue } from 'vue'
|
|
11
|
-
|
|
12
|
-
export const findPetsByTagsQueryKey = (params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>) =>
|
|
13
|
-
[{ url: '/pet/findByTags' }, ...(params ? [params] : [])] as const
|
|
14
|
-
|
|
15
|
-
export type FindPetsByTagsQueryKey = ReturnType<typeof findPetsByTagsQueryKey>
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* @description Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
|
19
|
-
* @summary Finds Pets by tags
|
|
20
|
-
* {@link /pet/findByTags}
|
|
21
|
-
*/
|
|
22
|
-
export async function findPetsByTags(
|
|
23
|
-
headers: FindPetsByTagsHeaderParams,
|
|
24
|
-
params?: FindPetsByTagsQueryParams,
|
|
25
|
-
config: Partial<RequestConfig> & { client?: Client } = {},
|
|
26
|
-
) {
|
|
27
|
-
const { client: request = fetch, ...requestConfig } = config
|
|
28
|
-
|
|
29
|
-
const res = await request<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, unknown>({
|
|
30
|
-
method: 'GET',
|
|
31
|
-
url: `/pet/findByTags`,
|
|
32
|
-
params,
|
|
33
|
-
...requestConfig,
|
|
34
|
-
headers: { ...headers, ...requestConfig.headers },
|
|
35
|
-
})
|
|
36
|
-
return findPetsByTagsQueryResponse.parse(res.data)
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
export function findPetsByTagsQueryOptions(
|
|
40
|
-
headers: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
41
|
-
params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
42
|
-
config: Partial<RequestConfig> & { client?: Client } = {},
|
|
43
|
-
) {
|
|
44
|
-
const queryKey = findPetsByTagsQueryKey(params)
|
|
45
|
-
return queryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, FindPetsByTagsQueryResponse, typeof queryKey>({
|
|
46
|
-
queryKey,
|
|
47
|
-
queryFn: async ({ signal }) => {
|
|
48
|
-
if (!config.signal) {
|
|
49
|
-
config.signal = signal
|
|
50
|
-
}
|
|
51
|
-
return findPetsByTags(toValue(headers), toValue(params), toValue(config))
|
|
52
|
-
},
|
|
53
|
-
})
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
/**
|
|
57
|
-
* @description Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
|
58
|
-
* @summary Finds Pets by tags
|
|
59
|
-
* {@link /pet/findByTags}
|
|
60
|
-
*/
|
|
61
|
-
export function useFindPetsByTags<
|
|
62
|
-
TData = FindPetsByTagsQueryResponse,
|
|
63
|
-
TQueryData = FindPetsByTagsQueryResponse,
|
|
64
|
-
TQueryKey extends QueryKey = FindPetsByTagsQueryKey,
|
|
65
|
-
>(
|
|
66
|
-
headers: MaybeRefOrGetter<FindPetsByTagsHeaderParams>,
|
|
67
|
-
params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
68
|
-
options: {
|
|
69
|
-
query?: Partial<UseQueryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, TData, TQueryData, TQueryKey>> & {
|
|
70
|
-
client?: QueryClient
|
|
71
|
-
}
|
|
72
|
-
client?: Partial<RequestConfig> & { client?: Client }
|
|
73
|
-
} = {},
|
|
74
|
-
) {
|
|
75
|
-
const { query: queryConfig = {}, client: config = {} } = options ?? {}
|
|
76
|
-
const { client: queryClient, ...queryOptions } = queryConfig
|
|
77
|
-
const queryKey = (queryOptions && 'queryKey' in queryOptions ? toValue(queryOptions.queryKey) : undefined) ?? findPetsByTagsQueryKey(params)
|
|
78
|
-
|
|
79
|
-
const query = useQuery(
|
|
80
|
-
{
|
|
81
|
-
...findPetsByTagsQueryOptions(headers, params, config),
|
|
82
|
-
...queryOptions,
|
|
83
|
-
queryKey,
|
|
84
|
-
} as unknown as UseQueryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, TData, FindPetsByTagsQueryResponse, TQueryKey>,
|
|
85
|
-
toValue(queryClient),
|
|
86
|
-
) as UseQueryReturnType<TData, ResponseErrorConfig<FindPetsByTags400>> & { queryKey: TQueryKey }
|
|
87
|
-
|
|
88
|
-
query.queryKey = queryKey as TQueryKey
|
|
89
|
-
|
|
90
|
-
return query
|
|
91
|
-
}
|
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generated by Kubb (https://kubb.dev/).
|
|
3
|
-
* Do not edit manually.
|
|
4
|
-
*/
|
|
5
|
-
import fetch from 'axios'
|
|
6
|
-
import type { MutationObserverOptions, QueryClient } from '@tanstack/vue-query'
|
|
7
|
-
import type { Client, RequestConfig, ResponseErrorConfig } from 'axios'
|
|
8
|
-
import type { MaybeRefOrGetter } from 'vue'
|
|
9
|
-
import { useMutation } from '@tanstack/vue-query'
|
|
10
|
-
|
|
11
|
-
export const updatePetWithFormMutationKey = () => [{ url: '/pet/:petId' }] as const
|
|
12
|
-
|
|
13
|
-
export type UpdatePetWithFormMutationKey = ReturnType<typeof updatePetWithFormMutationKey>
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* @summary Updates a pet in the store with form data
|
|
17
|
-
* {@link /pet/:petId}
|
|
18
|
-
*/
|
|
19
|
-
export async function updatePetWithForm(
|
|
20
|
-
petId: UpdatePetWithFormPathParams['petId'],
|
|
21
|
-
data?: UpdatePetWithFormMutationRequest,
|
|
22
|
-
params?: UpdatePetWithFormQueryParams,
|
|
23
|
-
config: Partial<RequestConfig<UpdatePetWithFormMutationRequest>> & { client?: Client } = {},
|
|
24
|
-
) {
|
|
25
|
-
const { client: request = fetch, ...requestConfig } = config
|
|
26
|
-
|
|
27
|
-
const requestData = updatePetWithFormMutationRequest.parse(data)
|
|
28
|
-
|
|
29
|
-
const res = await request<UpdatePetWithFormMutationResponse, ResponseErrorConfig<UpdatePetWithForm405>, UpdatePetWithFormMutationRequest>({
|
|
30
|
-
method: 'POST',
|
|
31
|
-
url: `/pet/${petId}`,
|
|
32
|
-
params,
|
|
33
|
-
data: requestData,
|
|
34
|
-
...requestConfig,
|
|
35
|
-
})
|
|
36
|
-
return updatePetWithFormMutationResponse.parse(res.data)
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
/**
|
|
40
|
-
* @summary Updates a pet in the store with form data
|
|
41
|
-
* {@link /pet/:petId}
|
|
42
|
-
*/
|
|
43
|
-
export function useUpdatePetWithForm<TContext>(
|
|
44
|
-
options: {
|
|
45
|
-
mutation?: MutationObserverOptions<
|
|
46
|
-
UpdatePetWithFormMutationResponse,
|
|
47
|
-
ResponseErrorConfig<UpdatePetWithForm405>,
|
|
48
|
-
{
|
|
49
|
-
petId: MaybeRefOrGetter<UpdatePetWithFormPathParams['petId']>
|
|
50
|
-
data?: MaybeRefOrGetter<UpdatePetWithFormMutationRequest>
|
|
51
|
-
params?: MaybeRefOrGetter<UpdatePetWithFormQueryParams>
|
|
52
|
-
},
|
|
53
|
-
TContext
|
|
54
|
-
> & { client?: QueryClient }
|
|
55
|
-
client?: Partial<RequestConfig<UpdatePetWithFormMutationRequest>> & { client?: Client }
|
|
56
|
-
} = {},
|
|
57
|
-
) {
|
|
58
|
-
const { mutation = {}, client: config = {} } = options ?? {}
|
|
59
|
-
const { client: queryClient, ...mutationOptions } = mutation
|
|
60
|
-
const mutationKey = mutationOptions?.mutationKey ?? updatePetWithFormMutationKey()
|
|
61
|
-
|
|
62
|
-
return useMutation<
|
|
63
|
-
UpdatePetWithFormMutationResponse,
|
|
64
|
-
ResponseErrorConfig<UpdatePetWithForm405>,
|
|
65
|
-
{ petId: UpdatePetWithFormPathParams['petId']; data?: UpdatePetWithFormMutationRequest; params?: UpdatePetWithFormQueryParams },
|
|
66
|
-
TContext
|
|
67
|
-
>(
|
|
68
|
-
{
|
|
69
|
-
mutationFn: async ({ petId, data, params }) => {
|
|
70
|
-
return updatePetWithForm(petId, data, params, config)
|
|
71
|
-
},
|
|
72
|
-
mutationKey,
|
|
73
|
-
...mutationOptions,
|
|
74
|
-
},
|
|
75
|
-
queryClient,
|
|
76
|
-
)
|
|
77
|
-
}
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generated by Kubb (https://kubb.dev/).
|
|
3
|
-
* Do not edit manually.
|
|
4
|
-
*/
|
|
5
|
-
import type { Client, RequestConfig, ResponseErrorConfig } from './test/.kubb/fetch'
|
|
6
|
-
import type { QueryKey, QueryClient, UseQueryOptions, UseQueryReturnType } from '@tanstack/react-query'
|
|
7
|
-
import type { MaybeRefOrGetter } from 'vue'
|
|
8
|
-
import { fetch } from './test/.kubb/fetch'
|
|
9
|
-
import { queryOptions, useQuery } from '@tanstack/react-query'
|
|
10
|
-
import { toValue } from 'vue'
|
|
11
|
-
|
|
12
|
-
export const findPetsByTagsQueryKey = (params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>) =>
|
|
13
|
-
[{ url: '/pet/findByTags' }, ...(params ? [params] : [])] as const
|
|
14
|
-
|
|
15
|
-
export type FindPetsByTagsQueryKey = ReturnType<typeof findPetsByTagsQueryKey>
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* @description Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
|
19
|
-
* @summary Finds Pets by tags
|
|
20
|
-
* {@link /pet/findByTags}
|
|
21
|
-
*/
|
|
22
|
-
export async function findPetsByTags(
|
|
23
|
-
headers: FindPetsByTagsHeaderParams,
|
|
24
|
-
params?: FindPetsByTagsQueryParams,
|
|
25
|
-
config: Partial<RequestConfig> & { client?: Client } = {},
|
|
26
|
-
) {
|
|
27
|
-
const { client: request = fetch, ...requestConfig } = config
|
|
28
|
-
|
|
29
|
-
const res = await request<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, unknown>({
|
|
30
|
-
method: 'GET',
|
|
31
|
-
url: `/pet/findByTags`,
|
|
32
|
-
params,
|
|
33
|
-
...requestConfig,
|
|
34
|
-
headers: { ...headers, ...requestConfig.headers },
|
|
35
|
-
})
|
|
36
|
-
return findPetsByTagsQueryResponse.parse(res.data)
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
export function findPetsByTagsQueryOptions(
|
|
40
|
-
headers: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
41
|
-
params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
42
|
-
config: Partial<RequestConfig> & { client?: Client } = {},
|
|
43
|
-
) {
|
|
44
|
-
const queryKey = findPetsByTagsQueryKey(params)
|
|
45
|
-
return queryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, FindPetsByTagsQueryResponse, typeof queryKey>({
|
|
46
|
-
queryKey,
|
|
47
|
-
queryFn: async ({ signal }) => {
|
|
48
|
-
if (!config.signal) {
|
|
49
|
-
config.signal = signal
|
|
50
|
-
}
|
|
51
|
-
return findPetsByTags(toValue(headers), toValue(params), toValue(config))
|
|
52
|
-
},
|
|
53
|
-
})
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
/**
|
|
57
|
-
* @description Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
|
58
|
-
* @summary Finds Pets by tags
|
|
59
|
-
* {@link /pet/findByTags}
|
|
60
|
-
*/
|
|
61
|
-
export function useFindPetsByTags<
|
|
62
|
-
TData = FindPetsByTagsQueryResponse,
|
|
63
|
-
TQueryData = FindPetsByTagsQueryResponse,
|
|
64
|
-
TQueryKey extends QueryKey = FindPetsByTagsQueryKey,
|
|
65
|
-
>(
|
|
66
|
-
headers: MaybeRefOrGetter<FindPetsByTagsHeaderParams>,
|
|
67
|
-
params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
68
|
-
options: {
|
|
69
|
-
query?: Partial<UseQueryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, TData, TQueryData, TQueryKey>> & {
|
|
70
|
-
client?: QueryClient
|
|
71
|
-
}
|
|
72
|
-
client?: Partial<RequestConfig> & { client?: Client }
|
|
73
|
-
} = {},
|
|
74
|
-
) {
|
|
75
|
-
const { query: queryConfig = {}, client: config = {} } = options ?? {}
|
|
76
|
-
const { client: queryClient, ...queryOptions } = queryConfig
|
|
77
|
-
const queryKey = (queryOptions && 'queryKey' in queryOptions ? toValue(queryOptions.queryKey) : undefined) ?? findPetsByTagsQueryKey(params)
|
|
78
|
-
|
|
79
|
-
const query = useQuery(
|
|
80
|
-
{
|
|
81
|
-
...findPetsByTagsQueryOptions(headers, params, config),
|
|
82
|
-
...queryOptions,
|
|
83
|
-
queryKey,
|
|
84
|
-
} as unknown as UseQueryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, TData, FindPetsByTagsQueryResponse, TQueryKey>,
|
|
85
|
-
toValue(queryClient),
|
|
86
|
-
) as UseQueryReturnType<TData, ResponseErrorConfig<FindPetsByTags400>> & { queryKey: TQueryKey }
|
|
87
|
-
|
|
88
|
-
query.queryKey = queryKey as TQueryKey
|
|
89
|
-
|
|
90
|
-
return query
|
|
91
|
-
}
|
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generated by Kubb (https://kubb.dev/).
|
|
3
|
-
* Do not edit manually.
|
|
4
|
-
*/
|
|
5
|
-
import type { Client, RequestConfig, ResponseErrorConfig } from './test/.kubb/fetch'
|
|
6
|
-
import type { QueryKey, QueryClient, UseQueryOptions, UseQueryReturnType } from '@tanstack/react-query'
|
|
7
|
-
import type { MaybeRefOrGetter } from 'vue'
|
|
8
|
-
import { fetch } from './test/.kubb/fetch'
|
|
9
|
-
import { queryOptions, useQuery } from '@tanstack/react-query'
|
|
10
|
-
import { toValue } from 'vue'
|
|
11
|
-
|
|
12
|
-
export const findPetsByTagsQueryKey = (params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>) =>
|
|
13
|
-
[{ url: '/pet/findByTags' }, ...(params ? [params] : [])] as const
|
|
14
|
-
|
|
15
|
-
export type FindPetsByTagsQueryKey = ReturnType<typeof findPetsByTagsQueryKey>
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* @description Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
|
19
|
-
* @summary Finds Pets by tags
|
|
20
|
-
* {@link /pet/findByTags}
|
|
21
|
-
*/
|
|
22
|
-
export async function findPetsByTags(
|
|
23
|
-
{ headers, params }: { headers: FindPetsByTagsHeaderParams; params?: FindPetsByTagsQueryParams },
|
|
24
|
-
config: Partial<RequestConfig> & { client?: Client } = {},
|
|
25
|
-
) {
|
|
26
|
-
const { client: request = fetch, ...requestConfig } = config
|
|
27
|
-
|
|
28
|
-
const res = await request<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, unknown>({
|
|
29
|
-
method: 'GET',
|
|
30
|
-
url: `/pet/findByTags`,
|
|
31
|
-
params,
|
|
32
|
-
...requestConfig,
|
|
33
|
-
headers: { ...headers, ...requestConfig.headers },
|
|
34
|
-
})
|
|
35
|
-
return findPetsByTagsQueryResponse.parse(res.data)
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
export function findPetsByTagsQueryOptions(
|
|
39
|
-
{ headers, params }: { headers: MaybeRefOrGetter<FindPetsByTagsQueryParams>; params?: MaybeRefOrGetter<FindPetsByTagsQueryParams> },
|
|
40
|
-
config: Partial<RequestConfig> & { client?: Client } = {},
|
|
41
|
-
) {
|
|
42
|
-
const queryKey = findPetsByTagsQueryKey(params)
|
|
43
|
-
return queryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, FindPetsByTagsQueryResponse, typeof queryKey>({
|
|
44
|
-
queryKey,
|
|
45
|
-
queryFn: async ({ signal }) => {
|
|
46
|
-
if (!config.signal) {
|
|
47
|
-
config.signal = signal
|
|
48
|
-
}
|
|
49
|
-
return findPetsByTags(toValue({ headers: toValue(headers), params: toValue(params) }), toValue(config))
|
|
50
|
-
},
|
|
51
|
-
})
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
/**
|
|
55
|
-
* @description Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
|
56
|
-
* @summary Finds Pets by tags
|
|
57
|
-
* {@link /pet/findByTags}
|
|
58
|
-
*/
|
|
59
|
-
export function useFindPetsByTags<
|
|
60
|
-
TData = FindPetsByTagsQueryResponse,
|
|
61
|
-
TQueryData = FindPetsByTagsQueryResponse,
|
|
62
|
-
TQueryKey extends QueryKey = FindPetsByTagsQueryKey,
|
|
63
|
-
>(
|
|
64
|
-
{ headers, params }: { headers: MaybeRefOrGetter<FindPetsByTagsHeaderParams>; params?: MaybeRefOrGetter<FindPetsByTagsQueryParams> },
|
|
65
|
-
options: {
|
|
66
|
-
query?: Partial<UseQueryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, TData, TQueryData, TQueryKey>> & {
|
|
67
|
-
client?: QueryClient
|
|
68
|
-
}
|
|
69
|
-
client?: Partial<RequestConfig> & { client?: Client }
|
|
70
|
-
} = {},
|
|
71
|
-
) {
|
|
72
|
-
const { query: queryConfig = {}, client: config = {} } = options ?? {}
|
|
73
|
-
const { client: queryClient, ...queryOptions } = queryConfig
|
|
74
|
-
const queryKey = (queryOptions && 'queryKey' in queryOptions ? toValue(queryOptions.queryKey) : undefined) ?? findPetsByTagsQueryKey(params)
|
|
75
|
-
|
|
76
|
-
const query = useQuery(
|
|
77
|
-
{
|
|
78
|
-
...findPetsByTagsQueryOptions({ headers, params }, config),
|
|
79
|
-
...queryOptions,
|
|
80
|
-
queryKey,
|
|
81
|
-
} as unknown as UseQueryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, TData, FindPetsByTagsQueryResponse, TQueryKey>,
|
|
82
|
-
toValue(queryClient),
|
|
83
|
-
) as UseQueryReturnType<TData, ResponseErrorConfig<FindPetsByTags400>> & { queryKey: TQueryKey }
|
|
84
|
-
|
|
85
|
-
query.queryKey = queryKey as TQueryKey
|
|
86
|
-
|
|
87
|
-
return query
|
|
88
|
-
}
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generated by Kubb (https://kubb.dev/).
|
|
3
|
-
* Do not edit manually.
|
|
4
|
-
*/
|
|
5
|
-
import type { Client, RequestConfig, ResponseErrorConfig } from './test/.kubb/fetch'
|
|
6
|
-
import type { QueryKey, QueryClient, UseQueryOptions, UseQueryReturnType } from '@tanstack/react-query'
|
|
7
|
-
import type { MaybeRefOrGetter } from 'vue'
|
|
8
|
-
import { fetch } from './test/.kubb/fetch'
|
|
9
|
-
import { queryOptions, useQuery } from '@tanstack/react-query'
|
|
10
|
-
import { toValue } from 'vue'
|
|
11
|
-
|
|
12
|
-
export const findPetsByTagsQueryKey = (params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>) =>
|
|
13
|
-
[{ url: '/pet/findByTags' }, ...(params ? [params] : [])] as const
|
|
14
|
-
|
|
15
|
-
export type FindPetsByTagsQueryKey = ReturnType<typeof findPetsByTagsQueryKey>
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* @description Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
|
19
|
-
* @summary Finds Pets by tags
|
|
20
|
-
* {@link /pet/findByTags}
|
|
21
|
-
*/
|
|
22
|
-
export async function findPetsByTags(
|
|
23
|
-
headers: FindPetsByTagsHeaderParams,
|
|
24
|
-
params?: FindPetsByTagsQueryParams,
|
|
25
|
-
config: Partial<RequestConfig> & { client?: Client } = {},
|
|
26
|
-
) {
|
|
27
|
-
const { client: request = fetch, ...requestConfig } = config
|
|
28
|
-
|
|
29
|
-
const res = await request<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, unknown>({
|
|
30
|
-
method: 'GET',
|
|
31
|
-
url: `/pet/findByTags`,
|
|
32
|
-
params,
|
|
33
|
-
...requestConfig,
|
|
34
|
-
headers: { ...headers, ...requestConfig.headers },
|
|
35
|
-
})
|
|
36
|
-
return findPetsByTagsQueryResponse.parse(res.data)
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
export function findPetsByTagsQueryOptions(
|
|
40
|
-
headers: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
41
|
-
params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
42
|
-
config: Partial<RequestConfig> & { client?: Client } = {},
|
|
43
|
-
) {
|
|
44
|
-
const queryKey = findPetsByTagsQueryKey(params)
|
|
45
|
-
return queryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, FindPetsByTagsQueryResponse, typeof queryKey>({
|
|
46
|
-
queryKey,
|
|
47
|
-
queryFn: async ({ signal }) => {
|
|
48
|
-
if (!config.signal) {
|
|
49
|
-
config.signal = signal
|
|
50
|
-
}
|
|
51
|
-
return findPetsByTags(toValue(headers), toValue(params), toValue(config))
|
|
52
|
-
},
|
|
53
|
-
})
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
/**
|
|
57
|
-
* @description Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
|
58
|
-
* @summary Finds Pets by tags
|
|
59
|
-
* {@link /pet/findByTags}
|
|
60
|
-
*/
|
|
61
|
-
export function useFindPetsByTags<
|
|
62
|
-
TData = FindPetsByTagsQueryResponse,
|
|
63
|
-
TQueryData = FindPetsByTagsQueryResponse,
|
|
64
|
-
TQueryKey extends QueryKey = FindPetsByTagsQueryKey,
|
|
65
|
-
>(
|
|
66
|
-
headers: MaybeRefOrGetter<FindPetsByTagsHeaderParams>,
|
|
67
|
-
params?: MaybeRefOrGetter<FindPetsByTagsQueryParams>,
|
|
68
|
-
options: {
|
|
69
|
-
query?: Partial<UseQueryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, TData, TQueryData, TQueryKey>> & {
|
|
70
|
-
client?: QueryClient
|
|
71
|
-
}
|
|
72
|
-
client?: Partial<RequestConfig> & { client?: Client }
|
|
73
|
-
} = {},
|
|
74
|
-
) {
|
|
75
|
-
const { query: queryConfig = {}, client: config = {} } = options ?? {}
|
|
76
|
-
const { client: queryClient, ...queryOptions } = queryConfig
|
|
77
|
-
const queryKey = (queryOptions && 'queryKey' in queryOptions ? toValue(queryOptions.queryKey) : undefined) ?? findPetsByTagsQueryKey(params)
|
|
78
|
-
|
|
79
|
-
const query = useQuery(
|
|
80
|
-
{
|
|
81
|
-
...findPetsByTagsQueryOptions(headers, params, config),
|
|
82
|
-
...queryOptions,
|
|
83
|
-
queryKey,
|
|
84
|
-
} as unknown as UseQueryOptions<FindPetsByTagsQueryResponse, ResponseErrorConfig<FindPetsByTags400>, TData, FindPetsByTagsQueryResponse, TQueryKey>,
|
|
85
|
-
toValue(queryClient),
|
|
86
|
-
) as UseQueryReturnType<TData, ResponseErrorConfig<FindPetsByTags400>> & { queryKey: TQueryKey }
|
|
87
|
-
|
|
88
|
-
query.queryKey = queryKey as TQueryKey
|
|
89
|
-
|
|
90
|
-
return query
|
|
91
|
-
}
|