Skip to content

The register mismatch between display value in input and reactive variable #10254

@vita1ya

Description

@vita1ya

Vue version

3.4.15

Link to minimal reproduction

play.vuejs.org

Steps to reproduce

Create a ref variable with a custom function to update value for it (for example, cast to lowercase) and add an input to do so. Enter the string aaaaa and try replacing the middle a with A (select the character and replace). The displayed value has changed to aaAaa, but the variable value has not changed. If you try to replace a with B, the value displayed and the value in the variable will be the same.

video.mov

What is expected?

The register of the displayed value in the input field corresponds to the value of the reactive variable

What is actually happening?

The register of the displayed value in the input field DOES NOT match the value of the reactive variable

System Info

System:
    OS: macOS 14.2.1
Browsers:
    Chrome: 121.0.6167.85
    Firefox: 122.0
    Safari: 17.2.1

Any additional comments?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions