Skip to content

Instantly share code, notes, and snippets.

@KolbySisk
Created August 26, 2022 18:18
Show Gist options
  • Save KolbySisk/e011d14853a5b6e2bc15c2dafdd3b492 to your computer and use it in GitHub Desktop.
Save KolbySisk/e011d14853a5b6e2bc15c2dafdd3b492 to your computer and use it in GitHub Desktop.
const formSchema = z
.object({
email: z.string().email(),
password: z.string().min(4),
passwordConfirm: z.string().min(4),
})
.refine((data) => data.password === data.passwordConfirm, {
message: "Passwords don't match",
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment