没使用作用域插槽:
<template>
<el-button
type="primary"
icon="el-icon-edit"
size="mini"
@click="showBox()"
></el-button>
</template>
开发环境正常显示,生产环境中的按钮消失。
使用作用域插槽:
<template slot-scope="scoped">
<el-button
type="primary"
icon="el-icon-edit"
size="mini"
@click="showBox(scoped)"
></el-button>
</template>
按钮就能正常显示。
原因未知,,有知道的大佬希望能评论帮萌新解解惑