this.$confirm({ title: this.$createElement('div', {}, [ "确定要删除", this.$createElement("span",{style: "color:red;"},`${this.selectKey?this.selectKey.name:''}的所有内容`), "吗?" ]), async onOk() { await that.confirmDelFun(that.selectKey.id); }, onCancel() { console.log('Cancel'); } }); const h = this.$createElement; const that = this this.$confirm({ title: h('div', {}, [ "确定要删除", h("span",{style: "color:red;"},`${that.selectTreeData.name}及其下的所有配置`), "吗?" ]), async onOk() { await that.delete(); }, onCancel() { console.log('Cancel'); } });