UNPKG

v-auth-image

Version:

Vue directive to load and display secured images by custom headers. 基于 Vue 的权限图片获取查看,提供加载成功或失败回调。

12 lines (9 loc) 254 B
import VAuthImage from './v-auth-image' const install = function (Vue,opts = {}) { Vue.use(VAuthImage, opts) } // 判断是否是直接引入文件 if (typeof window !== 'undefined' && window.Vue) { install(window.Vue); } export default VAuthImage