final-form / final-form/react-final-form

validateOnSubmit

Open
#655 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
7.4k
Forks
497
PR merge metrics
No merged PRs in 30d

Description

### Are you submitting a **bug report** or a **feature request**?
Feature request.

### What is the current behavior?
`` submission submits the parent ``.

### What is the expected behavior?
Via a `validateOnSubmit` attribute/property, `` would first run validation before submitting.

This would avoid [redundant code](https://stackoverflow.com/a/57006571/923745) per component.

### What's your environment?
final-form `4.18.5`
react `16.8.6`
react-dom `16.8.6`
react-final-form `6.3.0`
react-scripts `3.0.1`

Chrome `77.0.3865.120`
macOS `10.15`

### Other information

Contributor guide

Open the contributing guide

Research direction

Start by reviewing react-final-form's existing Form submission and validation behavior, using the reported final-form 4.18.5 and react-final-form 6.3.0 environment as context. Done means a validateOnSubmit attribute or property causes validation before the parent Form submits and avoids redundant per-component validation code.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react
Domain
frontend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.