Skip to content

Commit 67ab246

Browse files
committed
Added entry for build component plugin for vue
1 parent 31a5884 commit 67ab246

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

index.js

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import TinyPagination from './src/components/TinyPagination.vue'
2+
3+
export function install (Vue) {
4+
if (install.installed) return
5+
install.installed = true
6+
Vue.component(TynyPagination.name, TinyPagination)
7+
}
8+
9+
const plugin = {
10+
install
11+
}
12+
13+
let GlobalVue = null
14+
if (typeof window !== 'undefined') {
15+
GlobalVue = window.Vue
16+
} else if (typeof global !== 'undefined') {
17+
GlobalVue = global.Vue
18+
}
19+
if (GlobalVue) {
20+
GlobalVue.use(plugin)
21+
}
22+
23+
export default TinyPagination

0 commit comments

Comments
 (0)