From e038f12892e826b63dbb5ec38021aba732175df1 Mon Sep 17 00:00:00 2001 From: wxsm Date: Mon, 30 Aug 2021 09:28:04 +0800 Subject: [PATCH] Update custom-directives.md --- src/guide/migration/custom-directives.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/guide/migration/custom-directives.md b/src/guide/migration/custom-directives.md index ad5d45a9dc..84d1aae09b 100644 --- a/src/guide/migration/custom-directives.md +++ b/src/guide/migration/custom-directives.md @@ -15,8 +15,8 @@ Additionally, the `expression` string is no longer passed as part of the `bindin In Vue 2, custom directives were created by using the hooks listed below to target an element’s lifecycle, all of which are optional: -- **bind** - Occurs once the directive is bound to the element. Occurs only once. -- **inserted** - Occurs once the element is inserted into the parent DOM. +- **bind** - Called once the directive is bound to the element. Called only once. +- **inserted** - Called once the element is inserted into the parent DOM. - **update** - This hook is called when the element updates, but children haven't been updated yet. - **componentUpdated** - This hook is called once the component and the children have been updated. - **unbind** - This hook is called once the directive is removed. Also called only once.