浏览代码

no message

hzj18279462576@163.com 3 年之前
父节点
当前提交
46b65ba510
共有 1 个文件被更改,包括 6 次插入0 次删除
  1. 6 0
      admin/src/main.js

+ 6 - 0
admin/src/main.js

@@ -16,6 +16,12 @@ Vue.component('IconSvg', require('./components/SvgIcon').default)
 
 Vue.config.productionTip = false
 Vue.use(ElementUI);
+Vue.directive('fo', {
+  inserted(el, binding, vnode) {
+    // 聚焦元素
+    el.querySelector('input').focus()
+  }
+})
 
 /* eslint-disable no-new */
 new Vue({