We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
比如有state和stateText两个变量都放在store中:
export default { data: { state: 0, stateText: '未连接' } }
我希望在state的值改变的时候stateText也自动变为相应的文字,所以需要在onChange事件中监听state的变化然后修改stateText的值,但是在修改完成后调用update的时候又因为state的值还没有真正改变所以把修改state的diff又提交了一次,在这种情况下就导致了state的值永远也修改不了。
我想到的解决思路有两种:
为了简单易用且不影响其它参数的修改这里建议使用第一种方式,在实际修改store之后再去调用onChange。
The text was updated successfully, but these errors were encountered:
No branches or pull requests
比如有state和stateText两个变量都放在store中:
我希望在state的值改变的时候stateText也自动变为相应的文字,所以需要在onChange事件中监听state的变化然后修改stateText的值,但是在修改完成后调用update的时候又因为state的值还没有真正改变所以把修改state的diff又提交了一次,在这种情况下就导致了state的值永远也修改不了。
我想到的解决思路有两种:
为了简单易用且不影响其它参数的修改这里建议使用第一种方式,在实际修改store之后再去调用onChange。
The text was updated successfully, but these errors were encountered: