Skip to content

Commit

Permalink
refactor: import Plugin interface from vue-demi
Browse files Browse the repository at this point in the history
  • Loading branch information
mediv0 committed May 22, 2021
1 parent 08ee3c0 commit dd7d77b
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
import { Plugin } from "@vue/runtime-core";
import { Plugin } from "vue-demi";

import * as components from "./modules/index";

const install: Plugin = Vue => {
Object.values(components).forEach(cmp => {
Vue.component(cmp.name, cmp);
});
const plugin: Plugin = {
install(Vue) {
Object.values(components).forEach(cmp => {
Vue.component(cmp.name, cmp);
});
}
};

export default install;
export default plugin;

// export components
export { default as isPersian } from "./modules/isPersian";
Expand Down

0 comments on commit dd7d77b

Please sign in to comment.