Skip to content
This repository was archived by the owner on Aug 8, 2022. It is now read-only.

update slots-unification.md #739

Merged
merged 2 commits into from
Sep 19, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/guide/migration/slots-unification.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ badges:

## 2.x 语法

当使用渲染函数时,即 `h`,2.x 用于在内容节点上定义 `slot` 数据 property。
当使用渲染函数,即 `h`,2.x 曾经在内容节点上定义 `slot` 数据 property。

```js
// 2.x 语法
Expand All @@ -28,7 +28,7 @@ h(LayoutComponent, [
])
```

此外,在引用作用域插槽时,可以使用以下方法引用它们
此外,可以使用以下语法引用作用域插槽

```js
// 2.x 语法
Expand All @@ -37,7 +37,7 @@ this.$scopedSlots.header

## 3.x 语法

在 3.x 中,将插槽定义为当前节点的子对象
在 3.x 中,插槽以对象的形式定义为当前节点的子节点

```js
// 3.x Syntax
Expand All @@ -47,7 +47,7 @@ h(LayoutComponent, {}, {
})
```

当你需要以编程方式引用作用域插槽时,它们现在被统一到 `$slots` 选项中
当你需要以编程方式引用作用域插槽时,它们现在被统一到 `$slots` 选项中了

```js
// 2.x 语法
Expand Down