ci-plus 1.0.6 → 1.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.ts +8 -3
  2. package/package.json +1 -1
package/index.ts CHANGED
@@ -5,9 +5,14 @@ import { App } from 'vue';
5
5
  export default {
6
6
  install: (app: App) => {
7
7
  for (const c in components) {
8
- console.log("cccc", c);
9
-
10
- app.use(components[c]);
8
+ if (typeof components[c] === 'object' && components[c].constructor === Object) {
9
+ // 这是一个非组件类型的对象,需要移除
10
+ console.log('移除', components[c]);
11
+ } else {
12
+ // 这是一个组件类型的对象,可以使用 app.use()
13
+ console.log('加载', components[c]);
14
+ app.use(components[c]);
15
+ }
11
16
  }
12
17
  }
13
18
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ci-plus",
3
- "version": "1.0.6",
3
+ "version": "1.0.7",
4
4
  "description": "ci组件库",
5
5
  "main": "./index.ts",
6
6
  "scripts": {