Comments (3)
There is no way to make it default if you use bind:value
, as it will bind to the input field value, which is an empty string when empty.
from sveltekit-superforms.
An empty field is the same as an empty string. Use a stringProxy to set it to undefined when empty: https://stackblitz.com/edit/superforms-2-testing-ns3m6n?file=src%2Froutes%2F%2Bpage.svelte
from sveltekit-superforms.
Shouldn't that be the default, when using optional?
from sveltekit-superforms.
Related Issues (20)
- Support for schema references ($ref) HOT 6
- Target attribute not supported on <form> with use:enhance HOT 2
- Superdebug collapsed too much when without label HOT 7
- SuperForms doesn't quite support input names including `.` (setError(), splitPath()) HOT 1
- Support for "raw" JSON schema HOT 14
- isTainted does not allow to validate the entire form HOT 4
- Support for Valibot schema: instance HOT 3
- Support for Valibot schema: special HOT 3
- Manage client validation on multiple forms across stepper HOT 2
- Not able to use adapters from sveltekit-superforms
- Not able to use adapters from sveltekit-superforms HOT 2
- Support for Typia validator? HOT 1
- Capture/Restore doesn't reset form with list of files correctly after submitting HOT 3
- Differentiating between null & undefined HOT 1
- Not populate 0 value in input type number HOT 2
- Superforms hangs vite dev HOT 2
- superForms does something strange with form values (bind:value) HOT 1
- Using validators in +page.svelte with Async Validation, i.e., checking if email exisits is causing problem HOT 5
- json form losing value / resetting to previous value in svelte5 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sveltekit-superforms.