New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dropdown ignores 0 value #736
Comments
Could be the same issue with Autocomplete and Multiselect components. |
The issue is that 0 is evaluated as negative. A dirty workaround is to use '0' (as string) instead of 0 (as integer). A possible proposal as improvement for the component is to provide a property indicating which values are not empty. Example: If the model matches with any of the "notEmpty" property then do not consider as empty and hereby show the option in the dropdown list. |
IMHO only Of course, this can be a breaking change. If you don't want to do that, then I will go with something like the
Using this option, you could be confident using numbers without worring about |
Please look at the another example which we are considering to implement:
If I need to calculate the input value (see |
0 should be a valid value, this works in 3.x btw, will check for 2.x. |
We're unable to replicate on 2.x, please create a new ticket with a sample after testing with 2.2.3 |
primevue: ^2.2.1
the Dropdown not showing selected value which is
0
.For example:
The result is:
Should be:
The text was updated successfully, but these errors were encountered: