Skip to content
This repository has been archived by the owner on Nov 19, 2024. It is now read-only.

Zod preprocess works but coerce and tranform do not work with trpc-openapi #453

Open
ax-at opened this issue Jul 18, 2024 · 0 comments
Open

Comments

@ax-at
Copy link

ax-at commented Jul 18, 2024

When Zod's coerce and transform are used to modify the output schema, the generated OpenAPI document does not reflect those modifications. However, the API output reflects these modifications. Also, the TypeScript compiler shows errors about not being able to match between the .output() zod validation and the return type from the .query() method.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant