index.ts 553 B

123456789101112131415161718192021222324
  1. import modal from './modal';
  2. import tab from './tab';
  3. import download from './download';
  4. import cache from './cache';
  5. import auth from './auth';
  6. import { App } from 'vue';
  7. export default function installPlugin(app: App) {
  8. // 页签操作
  9. app.config.globalProperties.$tab = tab;
  10. // 模态框对象
  11. app.config.globalProperties.$modal = modal;
  12. // 缓存对象
  13. app.config.globalProperties.$cache = cache;
  14. // 下载文件
  15. app.config.globalProperties.$download = download;
  16. // 认证对象
  17. app.config.globalProperties.$auth = auth;
  18. }