Package
v4.x
Description
Just like native checkboxes, it would be useful for some cases (eg. data coming from MySQL or other DBs) when 1 is true, and 0 is false.
In Vue we can do
<input type="checkbox" v-model="myRef" :true-value="1" :false-value="0" />
But with USwitch or UCheckbox it doesn't work. This also messes up with validation schemas like Zod, which expects a number but the component toggles to boolean as soon as it's changed.
If this is wanted behavior, please suggest a workaround, but if possible please add the same :true-value="1" :false-value="0" logic to handle these cases
Additional context
No response
Package
v4.x
Description
Just like native checkboxes, it would be useful for some cases (eg. data coming from MySQL or other DBs) when 1 is true, and 0 is false.
In Vue we can do
But with
USwitchorUCheckboxit doesn't work. This also messes up with validation schemas like Zod, which expects a number but the component toggles to boolean as soon as it's changed.If this is wanted behavior, please suggest a workaround, but if possible please add the same
:true-value="1" :false-value="0"logic to handle these casesAdditional context
No response