element-plus/packages/message-box/index.ts

13 lines
430 B
TypeScript
Raw Normal View History

import { App } from 'vue'
import MessageBox from './src/messageBox'
2020-10-29 17:28:26 +08:00
(MessageBox as any).install = (app: App): void => {
app.config.globalProperties.$msgbox = MessageBox
app.config.globalProperties.$messageBox = MessageBox
app.config.globalProperties.$alert = MessageBox.alert
app.config.globalProperties.$confirm = MessageBox.confirm
app.config.globalProperties.$prompt = MessageBox.prompt
}
2020-10-29 17:28:26 +08:00
export default MessageBox