Skip to content

Commit 0830fc3

Browse files
committed
fix scopedSlots typos and add more info
1 parent 07a9bd4 commit 0830fc3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/v2/api/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1434,9 +1434,9 @@ type: api
14341434
14351435
**Note:** since 2.6.0+, there are two notable changes to this property:
14361436
1437-
1. Scoped slot functions now are guaranteed to return Array of VNodes, unless the return value is invalid, in which case the function will return `undefined`.
1437+
1. Scoped slot functions are now guaranteed to return an array of VNodes, unless the return value is invalid, in which case the function will return `undefined`.
14381438
1439-
2. All normal slots on `vm.$slots` are now also exposed on `vm.$scopeSlots` as functions. If you work with render functions, it is now recommended to always access all slots via `vm.$scopedSlots` for consistency.
1439+
2. All `$slots` are now also exposed on `$scopedSlots` as functions. If you work with render functions, it is now recommended to always access slots via `$scopedSlots`, whether they currently use a scope or not. This will not only make future refactors to add a scope simpler, but also ease your eventual migration to Vue 3, where all slots will be functions.
14401440
14411441
- **See also:**
14421442
- [`<slot>` Component](#slot-1)

0 commit comments

Comments
 (0)