Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blank field gives error even though optional #1332

Open
dwidge opened this issue May 2, 2024 · 0 comments
Open

Blank field gives error even though optional #1332

dwidge opened this issue May 2, 2024 · 0 comments
Labels
Bridge: Zod Affects the uniforms-bridge-zod package

Comments

@dwidge
Copy link

dwidge commented May 2, 2024

problem

If the schema is optional with a min length it won't accept it when you type something and then backspace it until empty again.

z.object({ text: z.string().min(1).optional() })

packages

import ZodBridge from "uniforms-bridge-zod";
import { AutoForm } from "uniforms-mui";
@piotrpospiech piotrpospiech added the Bridge: Zod Affects the uniforms-bridge-zod package label May 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bridge: Zod Affects the uniforms-bridge-zod package
Projects
Status: Needs triage
Development

No branches or pull requests

2 participants