-
-
Notifications
You must be signed in to change notification settings - Fork 3.3k
[vue] 你有写过自定义指令吗?自定义指令的生命周期(钩子函数)有哪些? #234
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Labels
vue
vue
Comments
v-focus; |
bind inserted update componentUpdated unbind |
这个问题像是个引子。接下来往下问什么才是重点吧? 这个问题不知道出处。 |
自定义指令的写法在Vue中,可以通过Vue.directive方法来创建自定义指令。自定义指令可以用于扩展Vue的功能,实现特定的DOM操作或交互行为。
自定义指令的生命周期钩子bind:在指令绑定到元素时调用,只调用一次。 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
[vue] 你有写过自定义指令吗?自定义指令的生命周期(钩子函数)有哪些?
The text was updated successfully, but these errors were encountered: