koel/resources/assets/js/directives/focus.js

11 lines
177 B
JavaScript
Raw Normal View History

2016-02-09 04:57:08 +00:00
import Vue from 'vue';
2015-12-13 04:42:28 +00:00
/**
* A simple directive to set focus into an input field when it's shown.
*/
export const focusDirective = {
2016-11-23 15:34:44 +00:00
inserted(el) {
el.focus();
2016-06-25 16:05:24 +00:00
},
2016-03-16 03:51:07 +00:00
};