Skip to content

[vue] 说说你对vue的表单修饰符.lazy的理解 #458

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

Open
haizhilin2013 opened this issue Jun 22, 2019 · 3 comments
Open

[vue] 说说你对vue的表单修饰符.lazy的理解 #458

haizhilin2013 opened this issue Jun 22, 2019 · 3 comments
Labels
vue vue

Comments

@haizhilin2013
Copy link
Collaborator

[vue] 说说你对vue的表单修饰符.lazy的理解

@haizhilin2013 haizhilin2013 added the vue vue label Jun 22, 2019
@wangjinA
Copy link

input标签v-model用lazy修饰之后,vue并不会立即监听input Value的改变,会在input失去焦点之后,才会触发input Value的改变

@Funtience
Copy link

v-model默认的触发条件是input事件,加了.lazy修饰符之后,v-model会在change事件触发的时候去监听

@jiangxiaohui000
Copy link

在默认情况下,v-model 在每次 input 事件触发后将输入框的值与数据进行同步 (除了(https://v3.cn.vuejs.org/guide/forms.html#vmodel-ime-tip)输入法组织文字时)。你可以添加 lazy 修饰符,从而转为在 change 事件之后进行同步:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
vue vue
Projects
None yet
Development

No branches or pull requests

4 participants