slot |
用于设置标签的属性值(slot=“title”) |
slot-scope |
|
v-slot |
|
slot
<el-menu-item v-if="!navMenu.children" :key="navMenu.id" :index="navMenu.id + ''" @click="itemClick(navMenu)" >
<span slot="title">{{ }}</span>
</el-menu-item>
<span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false">取 消</el-button>
<el-button type="primary" @click="save">确 定</el-button>
</span>
slot-scope
<el-table-column label="修改时间" width='150' align='center'>
<template slot-scope="scope">{{scope.row.modifyTime|formtterDate}}</template>
</el-table-column>
v-slot
<Test>
<template v-slot:header="scope">//v-slot定义作用域插槽
<div>
<p> {{scope.msg}} </p>
</div>
</template>
</Test>