rayyy-vue-table-components 1.2.28 → 1.2.30

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/README.md CHANGED
@@ -54,40 +54,41 @@ import App from './App.vue'
54
54
 
55
55
  const app = createApp(App)
56
56
 
57
- // 方式一:分別安裝(推薦)
58
- app.use(ElementPlus)
59
- app.use(VueTableComponents)
57
+ // 安裝 Element Plus(可自定義語系)
58
+ app.use(ElementPlus, {
59
+ locale: zhTw // 設定繁體中文
60
+ })
60
61
 
61
- // 方式二:使用組件庫內建的 Element Plus(自動設定繁體中文)
62
- // app.use(VueTableComponents, {
63
- // locale: zhTw // 可選,預設為繁體中文
64
- // })
62
+ // 安裝組件庫
63
+ app.use(VueTableComponents)
65
64
 
66
65
  app.mount('#app')
67
66
  ```
68
67
 
69
68
  ### 語系設定
70
69
 
71
- 組件庫內建繁體中文語系,您也可以自定義語系:
70
+ 組件庫依賴 Element Plus,請在安裝 Element Plus 時設定語系:
72
71
 
73
72
  ```typescript
74
73
  import { createApp } from 'vue'
74
+ import ElementPlus from 'element-plus'
75
75
  import zhTw from 'element-plus/es/locale/lang/zh-tw'
76
76
  import en from 'element-plus/es/locale/lang/en'
77
77
  import VueTableComponents from 'rayyy-vue-table-components'
78
78
 
79
79
  const app = createApp(App)
80
80
 
81
- // 使用繁體中文(預設)
82
- app.use(VueTableComponents, {
81
+ // 使用繁體中文
82
+ app.use(ElementPlus, {
83
83
  locale: zhTw
84
84
  })
85
85
 
86
86
  // 或使用英文
87
- app.use(VueTableComponents, {
87
+ app.use(ElementPlus, {
88
88
  locale: en
89
89
  })
90
90
 
91
+ app.use(VueTableComponents)
91
92
  app.mount('#app')
92
93
  ```
93
94