Yuri Huchok

Results 2 comments of Yuri Huchok

I am currently trying to accomplish a very similar thing for environment variables. Where the validation would only occur when the field is actually accessed at runtime. I think this...

For anybody encountering the same problem: I wrote a quick function to achieve the desired functionality. ``` function zodDefer(type: T) { return z.preprocess((value) => () => type.parse(value), z.function().returns(type)); } ```...