el is the current dom, that can be used directly. The second parameter of the custom instruction can get the parameter passed by the instruction
v-anchor="index"
function(el,binding){
var v = binding.value; // index
}
Previous: Win10 has its own hotspot, how to put it as an agent on the computer side?
Next: Elment-ui el-tree click how to rename, change the name
write an input box to build base-input , which focuses on managing styles and some ui logic. As the business expands, I need to customize the types that can be entered in the input box. Now I have written an instruction only-num , how to pass this in...
suppose I have an input, that can only enter numbers, and the length and the number of decimal places are limited, so I need two parameters. How can I pass it and get it in the instruction? here is the code that I pass a parameter or get, as follows: ...
the code is as follows: <no-ssr placeholder="" v-highlight> {{mycode}}<code style="atom-one-dark" :class="myCodeClass">{{mycode}} < no-ssr > const hljs = require( highlight.js ); Vue.directive(...