neko-ui 2.13.4 → 2.13.6
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 +13 -8
- package/package.json +2 -2
- package/umd/manifest.json +1 -1
package/README.md
CHANGED
|
@@ -32,7 +32,6 @@
|
|
|
32
32
|
[](https://github.com/monako97/neko-ui/actions/workflows/cd.yml)
|
|
33
33
|
[](https://app.fossa.com/projects/git%2Bgithub.com%2Fmonako97%2Fneko-ui?ref=badge_shield)
|
|
34
34
|
|
|
35
|
-
|
|
36
35
|
[![neko-ui][install-tag]][npm-url]
|
|
37
36
|
|
|
38
37
|
## 安装
|
|
@@ -55,10 +54,16 @@ pnpm add neko-ui -S
|
|
|
55
54
|
|
|
56
55
|
```html
|
|
57
56
|
<!-- 引入 CDN 资源 -->
|
|
58
|
-
<script src="https://cdn.jsdelivr.net/npm/neko-ui/
|
|
57
|
+
<script src="https://cdn.jsdelivr.net/npm/neko-ui/lib/index.js"></script>
|
|
58
|
+
<script>
|
|
59
|
+
const { Input } = NekoUI;
|
|
60
|
+
|
|
61
|
+
// 在使用前注册一次就行
|
|
62
|
+
NekoUI.registry(Input);
|
|
63
|
+
</script>
|
|
59
64
|
<!-- 使用 -->
|
|
60
65
|
<body>
|
|
61
|
-
<n-
|
|
66
|
+
<n-input></n-input>
|
|
62
67
|
</body>
|
|
63
68
|
```
|
|
64
69
|
|
|
@@ -66,14 +71,14 @@ pnpm add neko-ui -S
|
|
|
66
71
|
|
|
67
72
|
`neko-ui` 默认支持基于 ES modules 的 tree shaking,直接引入 `import { theme } from 'neko-ui';` 就会有按需加载的效果。
|
|
68
73
|
|
|
69
|
-
###
|
|
74
|
+
### 手动注册组件
|
|
70
75
|
|
|
71
76
|
```jsx
|
|
72
77
|
// 按需引入
|
|
73
|
-
import 'neko-ui
|
|
74
|
-
|
|
75
|
-
//
|
|
76
|
-
|
|
78
|
+
import { Button, DatePicker, registry } from 'neko-ui';
|
|
79
|
+
|
|
80
|
+
// 注册组件
|
|
81
|
+
registry(Button, DatePicker);
|
|
77
82
|
|
|
78
83
|
// 使用
|
|
79
84
|
function Demo() {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "neko-ui",
|
|
3
|
-
"version": "2.13.
|
|
3
|
+
"version": "2.13.6",
|
|
4
4
|
"description": "WebComponents UI Libraries",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "es/index.js",
|
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
"shadow-dom-testing-library": "1.12.0"
|
|
79
79
|
},
|
|
80
80
|
"dependencies": {
|
|
81
|
-
"@moneko/common": "1.
|
|
81
|
+
"@moneko/common": "1.9.0",
|
|
82
82
|
"@moneko/css": "1.2.0",
|
|
83
83
|
"custom-element-type": "1.0.7",
|
|
84
84
|
"dayjs": "1.11.13",
|
package/umd/manifest.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"filename":"manifest.json","name":"neko-ui","description":"WebComponents UI Libraries","start_url":"/?source=pwa","display":"standalone","background_color":"#fff","icons":[{"src":"/favicon.ico","sizes":"48x48","type":"image/x-icon"}],"version":"2.13.
|
|
1
|
+
{"filename":"manifest.json","name":"neko-ui","description":"WebComponents UI Libraries","start_url":"/?source=pwa","display":"standalone","background_color":"#fff","icons":[{"src":"/favicon.ico","sizes":"48x48","type":"image/x-icon"}],"version":"2.13.6-7a07c2304c8cdbcd","hash":"7a07c2304c8cdbcd","content_assets":["index.js"]}
|