Skip to content

onValueChange is not triggered when value is set via useForm defaultValues #883

@Sedivyk

Description

@Sedivyk

Describe the issue and the actual behavior
When a value is set via a form's default value rather than a key input, the onValueChange is not triggered.

Describe the expected behavior
The onValueChange should be triggered when the value is formatted by PatternFormat

Provide a CodeSandbox link illustrating the issue
https://codesandbox.io/p/sandbox/onvaluechange-not-triggered-fjntch

Provide steps to reproduce this issue
Open the provided CodeSandbox link
Observe that the combo does not show the formatted phone number as does the input using the PatternFormat

Version
Since version 5.2.0. Works until vesion5.1.4

Browsers where the issue is seen
Microsoft Edge

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions