npm sveltekit-superforms 2.29.1
v2.29.1

one day ago

Fixed

  • Fixed TypeScript type inference for discriminated unions in ValidationErrors. #653
  • Fixed FormData parsing for discriminated unions, so they work properly without requiring dataType: 'json'. #655
  • reset() function didn't preserve tainted state for fields that are not being reset when using partial data. #656
  • Fixed FormData parsing incorrectly coercing empty strings to literal values (e.g., z.literal("bar")). Empty strings now properly fail validation instead of being replaced with the literal value. #664
  • Fixed ReferenceError when using customValidity with validateForm({ update: true }). #669

Changed

  • Replaced deprecated @finom/zod-to-json-schema with zod-v3-to-json-schema. #660
  • Migrated Valibot adapter to use the official @valibot/to-json-schema package. #668

Don't miss a new sveltekit-superforms release

NewReleases is sending notifications on new releases.