Closed trim21 closed 1 year ago
I think we still need to support OpenAPI 3.0 too.
I think we still need to support OpenAPI 3.0 too.
I don't think this will break openapi 3.0, it just stop replacing examples
property in json schema object
Did I miss something?
I would move the
examples
mutation to the proper place that should happen.For example, resolveResponse. It can ensure, we are properly mutate the top-level only.
transformDefsToComponents
is called on path, params, response and query, this will require to write it multiple times
I guess you want to move examples
transform in schemaToMedia
?
Actually, cookie
, query
, path
, header
already doing it's own transform for the properties.examples
. There are no need to mutate the examples
for them.
For body
, it reuse the same logic inside schemaToMedia
which does require some mutation.
For response
, it is the only one need to do more things.
I think this is what you are expecting?
any releasing plan? I'm currently encountering a openapi rendering issue will be fixed by this PR.
Done in 8.2.1
Checklist
npm run test
andnpm run benchmark
fix https://github.com/fastify/fastify-swagger/issues/625