Skip to content

Fix field initial value validation#301

Merged
erikras merged 3 commits into
final-form:masterfrom
michaltk:fix-field-initial-value-validate
Jan 23, 2020
Merged

Fix field initial value validation#301
erikras merged 3 commits into
final-form:masterfrom
michaltk:fix-field-initial-value-validate

Conversation

@michaltk

Copy link
Copy Markdown
Contributor

fixes #296

When a field was registered with initialValue, form validation was never run on that value and therefore form remained invalid.

This pr changes to run form validation on field register when there's an initial value.

@michaltk michaltk changed the title Fix field initial value validate Fix field initial value validatation Nov 29, 2019
@michaltk michaltk changed the title Fix field initial value validatation Fix field initial value validation Nov 29, 2019
@codecov

codecov Bot commented Jan 23, 2020

Copy link
Copy Markdown

Codecov Report

Merging #301 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@          Coverage Diff          @@
##           master   #301   +/-   ##
=====================================
  Coverage     100%   100%           
=====================================
  Files          12     12           
  Lines         560    563    +3     
  Branches      116    116           
=====================================
+ Hits          560    563    +3
Impacted Files Coverage Δ
src/FinalForm.js 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a2047e0...c35117f. Read the comment docs.

@erikras
erikras merged commit 96b3b67 into final-form:master Jan 23, 2020
@erikras

erikras commented Jan 23, 2020

Copy link
Copy Markdown
Member

Published in v4.18.7.

@michaltk
michaltk deleted the fix-field-initial-value-validate branch January 24, 2020 00:21
@lock

lock Bot commented Feb 23, 2020

Copy link
Copy Markdown

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock Bot locked as resolved and limited conversation to collaborators Feb 23, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Field level initialValues don't validate before form is touched

3 participants