@owocow/saber-ui 0.0.1 → 0.0.2

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
@@ -12,7 +12,21 @@ npm install @owocow/saber-ui @nuxt/ui
12
12
 
13
13
  ## Usage
14
14
 
15
- ### Plugin (recommended)
15
+ ### Setup (recommended)
16
+
17
+ ```bash
18
+ npm install @owocow/saber-ui @nuxt/ui
19
+ ```
20
+
21
+ ```ts
22
+ // vite.config.ts
23
+ import vue from '@vitejs/plugin-vue'
24
+ import saberUI from '@owocow/saber-ui/vite'
25
+
26
+ export default defineConfig({
27
+ plugins: [vue(), saberUI()],
28
+ })
29
+ ```
16
30
 
17
31
  ```ts
18
32
  // main.ts
@@ -37,6 +51,8 @@ app.mount('#app')
37
51
 
38
52
  ### On-demand import
39
53
 
54
+ If you don't need the Vite plugin, import components directly:
55
+
40
56
  ```vue
41
57
  <script setup>
42
58
  import { BadgeStatus } from '@owocow/saber-ui'
@@ -50,6 +66,8 @@ import { BadgeStatus } from '@owocow/saber-ui'
50
66
  </template>
51
67
  ```
52
68
 
69
+ > **Note**: Without `@owocow/saber-ui/vite`, you need to configure `@nuxt/ui/vite` manually in your `vite.config.ts` and import Nuxt UI CSS manually.
70
+
53
71
  ## Components
54
72
 
55
73
  ### BadgeStatus
package/dist/vite.cjs ADDED
@@ -0,0 +1 @@
1
+ "use strict";const e=require("@nuxt/ui/vite");module.exports=e;
package/dist/vite.d.ts ADDED
@@ -0,0 +1 @@
1
+ export { default } from '@nuxt/ui/vite';
package/dist/vite.mjs ADDED
@@ -0,0 +1,4 @@
1
+ import { default as o } from "@nuxt/ui/vite";
2
+ export {
3
+ o as default
4
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@owocow/saber-ui",
3
- "version": "0.0.1",
3
+ "version": "0.0.2",
4
4
  "description": "Vue 3 component library — BadgeStatus and more, built on top of @nuxt/ui",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",
@@ -11,6 +11,11 @@
11
11
  "types": "./dist/index.d.ts",
12
12
  "import": "./dist/index.mjs",
13
13
  "require": "./dist/index.cjs"
14
+ },
15
+ "./vite": {
16
+ "types": "./dist/vite.d.ts",
17
+ "import": "./dist/vite.mjs",
18
+ "require": "./dist/vite.cjs"
14
19
  }
15
20
  },
16
21
  "files": [