We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello there ! Hope you're doing great, first of all thanks for the great job on that project ! It was a pleasure going through.
It seems like there's an issue while importing common models, shared between at least 2 controllers, when tag grouping apis.
Please find playground reproduction here, please select the Group by tag ( split files ):
Group by tag ( split files )
In case this is the used OpenApi spec
We can see that that in both Foo and Bar controllers FooBar schema import is missing
Foo
Bar
FooBar
// controller_foo.ts import { makeApi, Zodios, type ZodiosOptions } from "@zodios/core"; import { z } from "zod"; import { putFoo_Body } from "./common"; const endpoints = makeApi([ { method: "put", path: "/foo", description: `Foo`, requestFormat: "json", parameters: [ { name: "body", type: "Body", schema: putFoo_Body, }, ], // Cannot find name FooBar response: z.array(FooBar), }, ]); export const Controller_fooApi = new Zodios(endpoints); export function createApiClient(baseUrl: string, options?: ZodiosOptions) { return new Zodios(baseUrl, endpoints, options); }
This is just a solution suggestion, that might not be the most idiomatic. Please find #309
Please let me know your thoughts !
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Introduction
Hello there ! Hope you're doing great, first of all thanks for the great job on that project ! It was a pleasure going through.
The bug
It seems like there's an issue while importing common models, shared between at least 2 controllers, when tag grouping apis.
Reproduction
Please find playground reproduction here, please select the
Group by tag ( split files )
:In case this is the used OpenApi spec
We can see that that in both
Foo
andBar
controllersFooBar
schema import is missingA fix ?
This is just a solution suggestion, that might not be the most idiomatic.
Please find #309
Conclusion
Please let me know your thoughts !
The text was updated successfully, but these errors were encountered: