<!DOCTYPEhtml><htmllang="en"><head><metacharset="UTF-8"><title>同步执行 密码弹出框</title><linkrel="stylesheet"href="../css/element-index.css"><scripttype="text/javascript"src="../js/vue.js"></script><scripttype="text/javascript"src="../js/jquery.min.js"></script><scripttype="text/javascript"src="../js/element-index.js"></script></head><body><divid="app"v-cloak></div></body><script>var data ={}//VUE内容实现var vue =newVue({el:'#app',data: data,//初始加载asynccreated(){for(let i =1; i <=2; i++){awaitthis.$prompt('请输入密码:','提示',{confirmButtonText:'确定',cancelButtonText:'取消',inputType:'password',}).then(({value})=>{Vue.prototype.$message({type:'success',message: value
});}).catch(({value})=>{Vue.prototype.$message({type:'error',message:"你已取消当前操作"});return;});}},methods:{}})</script></html>