Skip to content

Instantly share code, notes, and snippets.

@diego3g
Last active October 31, 2017 22:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save diego3g/710ad95bc9df68986e8d47569c251fad to your computer and use it in GitHub Desktop.
Save diego3g/710ad95bc9df68986e8d47569c251fad to your computer and use it in GitHub Desktop.
handleSubmit: (values, { setSubmitting, setErrors }) => {
apiService.post('/authenticate', values)
.then(/* sucesso */)
.catch(err => {
setSubmitting(false);
setErrors({ message: err.message });
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment