Skip to content

v0.2.0

Compare
Choose a tag to compare
@thomashoneyman thomashoneyman released this 12 Aug 00:20
28477b6

This release represents a major change to Formless and brings in the following functionality:

  • You can now generate a record of symbol proxies from your Form type, reducing boilerplate

  • Validation and modification is now performed on a per-field basis with variants, rather than on the entire form using lenses; this fixes the limitation in Formless where validation would run across all fields when any field was changed and makes effectful validation possible.

  • Validators have access to the full form state on each run, as well as are able to access parent state for values from other forms to validate against.

  • FormSpec has been renamed to InputField; InputField has been renamed to FormField

  • There is a new Validation type which wraps a function from your overall form to a particular field input to some Either error output result. Polyform and purescript-validation adapters have been removed, as you can simply use the toEither functions from those libraries to make them compatible with Formless.

  • The Polyform example has been removed.

  • There are now modify, modifyValidate, and validate helpers which will create a correct Formless query from a symbol proxy for these major controls. See the overview for more information. There are also modify_, modifyValidate_, and validate_ versions which specify a Unit result for the query.