Fix FormState.values type to be non-optional#502
Merged
Conversation
FormState.values was incorrectly marked as optional in the TypeScript migration, but it's always initialized in the internal implementation and should never be undefined. This fixes type errors in v5 where consumers expect values to always be present.
JonathanWbn
marked this pull request as ready for review
June 13, 2025 19:56
|
Thanks @JonathanWbn ! Would it be possible to get this merged @erikras ? |
|
@erikras can we please revert type changes to this file? :) |
|
Still getting this issue on 5.0.0 because tag wasn't updated. |
|
@erikras can you make a release with this fix? |
|
@erikras any updates? |
Contributor
|
Published in |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
• Fix FormState.values type definition to be non-optional
• Resolves TypeScript errors in v5 where consumers expect values to always be present
Fixes #501
Test plan