¶Ô±ÈÐÂÎļþ |
| | |
| | | import Tab from './tab' |
| | | import Auth from './auth' |
| | | import Modal from './modal' |
| | | import Bus from './bus'; |
| | | import Socket from './socketclient' |
| | | import { App } from 'vue'; |
| | | |
| | | |
| | | export const tab = Tab; |
| | | export const auth = Auth; |
| | | export const modal = Modal; |
| | | export const bus = Bus |
| | | export const socket = Socket |
| | | |
| | | /** |
| | | * å¨ç»åå¼APIä¸å¯ä»¥éè¿ import { tab, auth, modal } form '@/plugins' æ¥ä½¿ç¨tabãauthãmodal |
| | | * å¨é项å¼APIä¸å¯ä»¥éè¿ this.$tab this.$auth this.$modal æ¥ä½¿ç¨tabãauthãmodal |
| | | */ |
| | | export default { |
| | | install(app: App): void { |
| | | // é¡µé¢æä½ |
| | | app.config.globalProperties.$tab = tab |
| | | // 认è¯å¯¹è±¡ |
| | | app.config.globalProperties.$auth = auth |
| | | // æ¨¡ææ¡å¯¹è±¡ |
| | | app.config.globalProperties.$modal = modal |
| | | // å
¨å±äºä»¶æ»çº¿ |
| | | app.config.globalProperties.$bus = bus |
| | | // socket对象 |
| | | app.config.globalProperties.$socket = socket |
| | | } |
| | | } |