Skip to content

Commit da57d9f

Browse files
committed
Another test fix
1 parent f0e8d0d commit da57d9f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/routes/(v2)/v2/submit-json/+page.svelte

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@
99
taintedMessage: false,
1010
dataType: 'json',
1111
validators: zod(schema),
12-
onSubmit({ jsonData }) {
12+
onSubmit({ jsonData, validators, formData }) {
13+
if (formData.has('skip')) validators(false);
1314
jsonData({ ...$form, email: 'no-email' });
1415
}
1516
});
@@ -35,6 +36,7 @@
3536
{#if $errors.email}<span class="invalid">{$errors.email}</span>{/if}
3637
</label>
3738
<div>
39+
<input type="checkbox" name="skip" /> Skip client-side validation<br />
3840
<button>Submit</button>
3941
</div>
4042
</form>

0 commit comments

Comments
 (0)