Skip to content

fix(Select): mergedValue shouldn't modified by outValue #4670

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 19, 2021
Merged

fix(Select): mergedValue shouldn't modified by outValue #4670

merged 1 commit into from
Sep 19, 2021

Conversation

ylc395
Copy link
Contributor

@ylc395 ylc395 commented Sep 18, 2021

First of all, thank you for your contribution! 😄

New feature please send pull request to feature branch, and rest to master branch. Pull request will be merged after one of collaborators approve. Please makes sure that these form are filled before submitting your pull request, thank you!

[中文版模板 / Chinese template]

This is a ...

  • New feature
  • Bug fix
  • Site / document update
  • Component style update
  • TypeScript definition update
  • Refactoring
  • Code style optimization
  • Branch merge
  • Other (about what?)

What's the background?

<Select :value="myValue" @change="handleChange">

现象:在 handleChange 中修改myValue(一个 ref 对象)的值,Select 展示的当前值和myValue的实际值不一致。

解决方法:mergedValue应当仅受 props 上的 value控制

@ylc395 ylc395 requested a review from tangjinzhou September 18, 2021 16:35
@tangjinzhou tangjinzhou merged commit 2e22b22 into vueComponent:next Sep 19, 2021
@github-actions
Copy link

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

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 19, 2022
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.

2 participants