im-ui-mobile 0.0.36 → 0.0.38

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.
package/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { UViewPlusPlugin } from './plugins/uview-plus'
1
+ import { UViewPlusPlugin } from './plugins/uview-plus.js'
2
2
  import ImChat from './components/im-chat/im-chat.vue'
3
3
 
4
4
  // 重要:为组件添加名称,以支持开发环境
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "im-ui-mobile",
3
- "version": "0.0.36",
3
+ "version": "0.0.38",
4
4
  "description": "A Vue3.0 + typescript instant messaging component library for Uniapp",
5
5
  "type": "module",
6
6
  "main": "index.js",
@@ -10,6 +10,7 @@
10
10
  "libs",
11
11
  "types",
12
12
  "utils",
13
+ "plugins",
13
14
  "index.js"
14
15
  ],
15
16
  "scripts": {
@@ -0,0 +1,14 @@
1
+ import uviewPlus from 'uview-plus'
2
+
3
+ export const UViewPlusPlugin = {
4
+ install(app) {
5
+ // 安装 uview-plus
6
+ app.use(uviewPlus)
7
+
8
+ // 注册一些常用的 uview-plus 组件作为全局组件
9
+ app.component('UButton', uviewPlus.Button)
10
+ app.component('UInput', uviewPlus.Input)
11
+ app.component('UAvatar', uviewPlus.Avatar)
12
+ app.component('UBadge', uviewPlus.Badge)
13
+ }
14
+ }