@ebolax/animated-icons 1.0.3 → 1.0.5
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 +31 -0
- package/dist/animated-icons.bundle.min.css +1 -0
- package/dist/animated-icons.min.css +1 -1
- package/dist/index.html +32 -4
- package/package.json +10 -5
package/README.md
CHANGED
|
@@ -18,8 +18,33 @@ npm i @ebolax/animated-icons
|
|
|
18
18
|
```
|
|
19
19
|
After installing, link the stylesheet from `node_modules/ebolax-animated-icons/dist/animated-icons.css` (or the minified `animated-icons.min.css`) and use the icon classes as shown below.
|
|
20
20
|
|
|
21
|
+
If you prefer an even simpler setup with no dependency on the `aic-icons` directory, you can use the bundled CSS file:
|
|
22
|
+
|
|
23
|
+
```html
|
|
24
|
+
<link rel="stylesheet" href="/path/to/animated-icons.bundle.min.css">
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
This includes all icons and necessary styles as embedded assets (using data URLs), so you **do not need to copy or serve the `aic-icons` folder**. Just use the icon classes in your HTML as usual, and everything will work out of the box.
|
|
28
|
+
|
|
29
|
+
|
|
21
30
|
You can also copy the `animated-icons.css` file and the `aic-icons` directory from the `dist/` folder to any location in your project. Once copied, update the `<link>` tag `href` and the icon asset paths accordingly, and the icons will work independently from your `node_modules` directory.
|
|
22
31
|
|
|
32
|
+
You can also import the CSS directly in your JavaScript or TypeScript project.
|
|
33
|
+
For example, with modern bundlers (like Vite, Webpack, or esbuild):
|
|
34
|
+
|
|
35
|
+
```js
|
|
36
|
+
import "@ebolax/animated-icons";
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
Or, if you are using CommonJS:
|
|
40
|
+
|
|
41
|
+
```js
|
|
42
|
+
require("@ebolax/animated-icons");
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
This will automatically bundle and apply the icon CSS to your project, without manually adding a `<link>` tag.
|
|
46
|
+
|
|
47
|
+
|
|
23
48
|
**Manual Install**
|
|
24
49
|
|
|
25
50
|
```bash
|
|
@@ -43,6 +68,12 @@ This generates:
|
|
|
43
68
|
|
|
44
69
|
You can also copy the contents of `animated-icons.css` and `aic-icons` directory into your own bundle.
|
|
45
70
|
|
|
71
|
+
If you prefer an even simpler setup with no dependency on the `aic-icons` directory, you can use the bundled CSS file:
|
|
72
|
+
|
|
73
|
+
```html
|
|
74
|
+
<link rel="stylesheet" href="/path/to/animated-icons.bundle.min.css">
|
|
75
|
+
```
|
|
76
|
+
|
|
46
77
|
---
|
|
47
78
|
|
|
48
79
|
## Basic usage
|