14.03 Custom Directive - Make it Global!
This commit is contained in:
1 parent
3057951d6a
commit
e2f0100f36
3 files changed
+20
-13
No files matched your search
@@ -0,0 +1,10 @@
|
||||
export const selectAll = {
|
||||
inserted (el) {
|
||||
const input = el.querySelector('.q-field__native')
|
||||
input.addEventListener('focus', () => {
|
||||
if (input.value.length) {
|
||||
input.select()
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user