-
Notifications
You must be signed in to change notification settings - Fork 406
Re-use generated interfaces for $ref in allOf #154
New issue
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
Comments
Hi @vsund! We use the presence of the You might run into an issue where we generate the linked schema twice - let me know what the result is! |
Thanks for the help! Indeed generated twice:
|
This is a known issue #16. You could avoid compiling Account.json for now, or you could send a PR for the issue :) In either case this shouldn't affect anything -- TS will merge the two |
Yeah, it's basically only the ugly output. But since I don't commit these files I think it's ok :) Thanks for all the help! ;) |
Hey,
I tried to externalize some complex properties from my main schema
Person.json
to use the (sub) interfaces separately in the code.For example my
Person.json
schema has anaccount
property and I put the schema from this intocomponents/Account.json
.It would be cool to re-use the declared interfaces for these types. E.g.
For all the used schemas etc see below. Please note that I simplified the schema, if something doesn't match please let me know.
Person.json
components/Account.json
Person.json.d.ts
components/Account.json.d.ts
The text was updated successfully, but these errors were encountered: