Skip to content

Nextlove should support .optional() on formData #122

@seveibar

Description

@seveibar

We currently can't do z.object({ ... }).optional() with nextlove's formData, it will always fail to parse, so instead we do a hack where we do z.union([z.any(), z.object({ ... })]), let's fix this!

          yea this is imo a nextlove bug, we should be able to do `.optional()`

Originally posted by @seveibar in https://github.com/seamapi/seam-connect/pull/4685#discussion_r1371085647

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions