forms-js / discussions

6 stars 0 forks source link

Loose Schema #10

Open mohsen1 opened 9 years ago

mohsen1 commented 9 years ago

{} is a valid JSON Schema, it's a schema for any JSONObject. Should we allow this? If yes, how? This also raises the question about what should happen when additionalProperties is true?

One proposal is to allow user to enter key and value. Something like this:

<input title="key">:<input title="value">
<button>Add row</button>
bvaughn commented 9 years ago

formFor punts on the collections markup. It allows for the validation of collections (min length, max length, etc.) and items within the collection (full validation supported) but requires external user to add controls for adding/removing objects from the collection. (Items added to the collection may be complex items without default constructors. We're likely not talking about simple primitives.)

Example: http://bvaughn.github.io/angular-form-for/#/demo/collections-form