How to use js in vue to pop up the Dialog dialog box of elementUI? Can play MessageBox but not Dialog

the following code can play an elementUI MessageBox pop-up box without writing HTML

what should I do if I want to play a Dialog with an input box or something without writing HTML?


import { MessageBox } from "element-ui"

MessageBox(message, "", {
  confirmButtonText: ""
})
Jun.21,2021

MessageBox can also have input boxes
example


<template>
  <el-button type="text" @click="open"> Message Box</el-button>
</template>

<script>
  export default {
    methods: {
      open() {
        this.$alert('', '', {
          confirmButtonText: '',
          callback: action => {
            this.$message({
              type: 'info',
              message: `action: ${ action }`
            });
          }
        });
      }
    }
  }
</script>

dialog official tutorial
https://element.eleme.io/-sharp/zh.

I hope it will be useful to you. Welcome to follow my official account of Wechat: Front-end Guide
Menu