FAQ: update attribute `slot-scope` for Vue 2.5.0+

pull/7923/head
spiritree 2017-11-01 09:54:18 +08:00 committed by 杨奕
parent 7d7d5a8757
commit 1582da7c53
1 changed files with 2 additions and 2 deletions

4
FAQ.md
View File

@ -22,7 +22,7 @@
使用 [Scoped slot](https://vuejs.org/v2/guide/components.html#Scoped-Slots) 即可: 使用 [Scoped slot](https://vuejs.org/v2/guide/components.html#Scoped-Slots) 即可:
```html ```html
<el-table-column label="操作"> <el-table-column label="操作">
<template scope="props"> <template slot-scope="props">
<el-button @click.native="showDetail(props.row)">查看详情</el-button> <el-button @click.native="showDetail(props.row)">查看详情</el-button>
</template> </template>
</el-table-column> </el-table-column>
@ -115,7 +115,7 @@ For other components, the `.native` modifier is still mandatory.
Just use [Scoped slot](https://vuejs.org/v2/guide/components.html#Scoped-Slots): Just use [Scoped slot](https://vuejs.org/v2/guide/components.html#Scoped-Slots):
```html ```html
<el-table-column label="Operations"> <el-table-column label="Operations">
<template scope="props"> <template slot-scope="props">
<el-button @click.native="showDetail(props.row)">Details</el-button> <el-button @click.native="showDetail(props.row)">Details</el-button>
</template> </template>
</el-table-column> </el-table-column>