Skip to content

Commit 97fb12d

Browse files
skirtles-codeyyx990803
authored andcommitted
docs: document the removal of binding.expression (#1133)
1 parent 7da45d0 commit 97fb12d

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/guide/migration/custom-directives.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ badges:
99

1010
The hook functions for directives have been renamed to better align with the component lifecycle.
1111

12+
Additionally, the `expression` string is no longer passed as part of the `binding` object.
13+
1214
## 2.x Syntax
1315

1416
In Vue 2, custom directives were created by using the hooks listed below to target an element’s lifecycle, all of which are optional:

src/guide/migration/introduction.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ The following consists a list of breaking changes from 2.x:
101101
- The `destroyed` lifecycle option has been renamed to `unmounted`
102102
- The `beforeDestroy` lifecycle option has been renamed to `beforeUnmount`
103103
- [Props `default` factory function no longer has access to `this` context](/guide/migration/props-default-this.html)
104-
- [Custom directive API changed to align with component lifecycle](/guide/migration/custom-directives.html)
104+
- [Custom directive API changed to align with component lifecycle and `binding.expression` removed](/guide/migration/custom-directives.html)
105105
- [The `data` option should always be declared as a function](/guide/migration/data-option.html)
106106
- [The `data` option from mixins is now merged shallowly](/guide/migration/data-option.html#mixin-merge-behavior-change)
107107
- [Attributes coercion strategy changed](/guide/migration/attribute-coercion.html)

0 commit comments

Comments
 (0)