react-router-form icon indicating copy to clipboard operation
react-router-form copied to clipboard

Write documentation

Open insin opened this issue 10 years ago • 1 comments

insin avatar Oct 23 '15 10:10 insin

Some things that can only be found in the source code atm:

Optional Properties

  • component: what HTML component to render as the enclosing <form>. Defaults to form.
  • dataKey: what key to place extracted form data in, i.e. location.state[dataKey]. Defaults to body.
  • extractFormData: function to use to extract form data into JS object. Receives event.target. Defaults to get-form-data.
  • methodKey: what key to place extracted form submission method in, i.e. location.state[methodKey]. Defaults to method.
  • onSubmit: function to run on form submission. Receives (event, formData) where event is the SyntheticEvent and formData is the extracted form data (see extractFormData). Defaults to null.

citelao avatar Feb 02 '17 18:02 citelao