2022年3月8日

指令——v-text ,v-html, v-show ,v-if v-else v-else-if ,v-for ,v-on ,v-bind ,v-model, v-slot ,v-pre ,v-once, v-memo ,v-cloak

摘要: ###指令综述 |指令|作用| | | | |v-text|通过设置元素的textContent属性来工作,因此它将覆盖元素内的任何现有内容。如果你需要更新| |v-html|作为纯html插入,不会处理Vue模板语法。(谨慎使用)可尝试改用组件来重新考虑解决方案,在网站上动态呈现任意html可能非 阅读全文

posted @ 2022-03-08 20:08 In-6026 阅读(95) 评论(0) 推荐(0)

事件——内置指令

摘要: 指令 作用 v-focus 聚焦 <input v-focus /> 阅读全文

posted @ 2022-03-08 16:24 In-6026 阅读(39) 评论(0) 推荐(0)

事件——事件修饰符.stop,.prevent,.self,.capture,.once,.passive

摘要: 修饰符 作用 .stop e.stopPropagation() .prevent e.preventDefault .self 在F节点的任意事件上加该后缀,则F的所有子节点 (是子,"孙"可不归我管) 相当于都加上了.stop,不要再手动加(感觉是个比.stop更厉害的) .capture 顾名 阅读全文

posted @ 2022-03-08 15:34 In-6026 阅读(141) 评论(0) 推荐(0)

导航