remix-params-helper
remix-params-helper copied to clipboard
Handle ZodUnion types in processDef()
Updated the processDef() function to properly handle ZodUnion types in the Zod schema. When encountering a ZodUnion, the function now tries to parse the value with each option of the union until one succeeds. If parsing fails with all options, an error will be thrown. This ensures that ZodUnion types are correctly processed during data validation.