vue-pro-table
Version:
一个基于ElementUI封装的table列表页组件,将包含搜索、列表、分页等功能的页面封装成一个组件
24 lines (19 loc) • 499 B
JavaScript
import Component from "./components/index.vue";
function install (Vue, options = {}) {
if (install.installed) return;
install.installed = true;
Vue.component("vue-pro-table", Component);
}
Component.install = install;
// auto plugin install
let GlobalVue = null;
if (typeof window !== "undefined") {
GlobalVue = window.Vue;
} else if (typeof global !== "undefined") {
GlobalVue = global.vue;
}
if (GlobalVue) {
GlobalVue.use(Component);
}
// export default
export default Component;