You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Constraints are only available on the client when you have used superValidate. The "undocumented" way you're using superForm` now (send an object to it directly) won't be able to figure them out automatically.
Description
I'm using Superforms with Valibot in SPA Mode but
$constraints
are empty ({}
).The form validation seems to be working and displays all errors correctly but when I want to use
$constraints
of a field it is empty.I tried it with a Zod Schema but it's also empty.
When using the official tutorial (from docs) that is creating the form on the server then
$constraints
its populated correctly.MRE
Valibot:
https://www.sveltelab.dev/9mybppcxpyhugni?files=.%2Fsrc%2Froutes%2F%2Bpage.svelte
Zod:
https://www.sveltelab.dev/9mybppcxpyhugni?files=.%2Fsrc%2Froutes%2Fzod%2F%2Bpage.svelte
The text was updated successfully, but these errors were encountered: