Element-ui Dialog对话框基本使用
作者:菜园前端
这篇文章主要为大家介绍了Element-ui Dialog对话框基本使用示例,有需要的朋友可以借鉴参考下,希望能够有所帮助,祝大家多多进步,早日升职加薪
按需引入方式
Element-ui Dialog对话框用于弹出窗口
如果是完整引入可跳过此步骤
import Vue from 'vue'
import { Dialog } from 'element-ui'
import 'element-ui/lib/theme-chalk/base.css'
import 'element-ui/lib/theme-chalk/dialog.css'
Vue.use(Dialog)基础使用
<template>
<el-button @click="dialogVisible = true">点击打开 Dialog</el-button>
<el-dialog title="提示" :visible.sync="dialogVisible" width="30%">
<span>这是一段信息</span>
<span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false">取 消</el-button>
<el-button type="primary" @click="dialogVisible = false">确 定</el-button>
</span>
</el-dialog>
</template>
<script>
export default {
data() {
return {
dialogVisible: false
}
}
}
</script>Attributes

以上就是Element-ui Dialog 对话框基本使用的详细内容,更多关于Element-ui Dialog对话框的资料请关注脚本之家其它相关文章!
