You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is an exact issue we're running into in our project currently. Will this be resolved at any time?
I've tried to have a look at the related issue (#586), but this seems to be something that can be included without the challenges presented and discussed in that issue.
Hi there,
If a header is specified as a reference (i.e. as part of a response) the header isn't included in the produced objects.
An example response schema is:
That would produce a type with:
The reason is because of the check:
https://github.com/drwpow/openapi-typescript/blob/e2fb371f053c90af4d958c48b7b6b04271b257ca/src/transform/headers.ts#L17
v.schema
won't be defined because the header is included by reference.Properly handling the headers relies on resolving the reference (even if it is external).
Since the majority of my PR has not been merged that deals with resolving references, I'm going to just link to the commit that fixes this problem:
rustyconover@9c21864
Please feel free to cherry pick.
Rusty
The text was updated successfully, but these errors were encountered: