foxhound87 / mobx-react-form

Reactive MobX Form State Management
https://foxhound87.github.io/mobx-react-form
MIT License
1.09k stars 129 forks source link

Add new type 'nullable' #578

Closed riceyeh closed 2 years ago

riceyeh commented 3 years ago

A field's type could be one of 'date', 'datetime-local', 'checkout', and 'number' and their default values are null, null, false, and 0 respectively. If a widget's type does not fit to any of the above types, its default value is the empty string ''. However, this could cause problem when trying to bind a field to a widget that '' is not an acceptable value, like Autocomplete from https://material-ui.com/ . I suggest to add a new type 'nullable' and its default value is null because I find many widgets from ui libraries accept null as default value.

foxhound87 commented 2 years ago

:tada: This issue has been resolved in version 3.1.2 :tada:

The release is available on:

Your semantic-release bot :package::rocket: