Skip to content
On this page

自定义指令

v-focus 自动聚焦

基础用法:<el-input v-focus />

基础用法

说明

  • v-focus 用于在元素挂载后自动聚焦输入框。
  • 指令可以直接绑定在原生 input,也可以绑定在内部包含 input 的组件上,例如 el-input

思云博智私有前端组件库