Support for `z.readonly()`
There is currently no support for returning readonly arrays/object. This can be modelled with zod using e.g. z.array(...).readonly() since zod version 3.22.0. When using .readonly the resulting schema would be empty due to missing support from zod-to-json-schema.
I raised this issue with zod-to-json-schema here: https://github.com/StefanTerdell/zod-to-json-schema/issues/90
Now that the issue has been fixed with zod-to-json-schema version 3.22.0, support can be added to fastify-type-provider-zod simply by upgrading to version 3.22.0 as well.
@thorhj can you send a PR with test?
@kibertoad Yes, but I don't have a lot of time currently so it may take some time 🥲