koumoul-dev / vuetify-jsonschema-form

Create beautiful and low-effort forms that output valid data. Published on npm as @koumoul/vjsf.
https://koumoul-dev.github.io/vuetify-jsonschema-form/latest/
MIT License
548 stars 155 forks source link

Array of strings not nullable #239

Closed ibot3 closed 1 month ago

ibot3 commented 3 years ago

When using an array of strings, vjsf always expects the model to be a list. Supplying null as value, throws errors:

Error in beforeMount hook: 'TypeError: can't access property 'map', e is null'

https://codepen.io/ibot3/pen/VwPXdJr?editors=1011

Also adding null ass additional type does not help, the field just disappears in this case. It would be great if the field would be "clearable" or at least does not throw an error if null is used in the model. It could be just assumed as empty list instead.