@hugeicons/core-free-icons 3.0.0 → 3.1.1
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 +87 -41
- package/dist/cjs/index.js +1308 -0
- package/dist/cjs/index.min.js +1 -1
- package/dist/esm/index.js +859 -859
- package/dist/esm/index.min.js +1 -1
- package/dist/types/index.d.ts +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,52 +1,95 @@
|
|
|
1
1
|
# @hugeicons/core-free-icons
|
|
2
2
|
|
|
3
|
-
> Hugeicons
|
|
4
|
-
|
|
5
|
-

|
|
3
|
+
> Hugeicons core icon package - Raw SVG icon data for use with framework wrappers
|
|
6
4
|
|
|
7
5
|
## What is Hugeicons?
|
|
8
6
|
|
|
9
|
-
Hugeicons is a
|
|
7
|
+
Hugeicons is a large icon set for modern web and mobile apps. The free package includes 4,600+ Stroke Rounded icons across 59 categories. The Pro package provides 46,000+ icons across 10 styles with multicolor support for Bulk, Duotone, and Twotone styles.
|
|
8
|
+
|
|
9
|
+
## How It Works
|
|
10
|
+
|
|
11
|
+
This package (`@hugeicons/core-free-icons`) provides **raw icon data** - it contains the SVG paths and elements for each icon. To render icons in your app, you need to install the corresponding **framework wrapper**:
|
|
12
|
+
|
|
13
|
+
| Framework | Wrapper Package |
|
|
14
|
+
|-----------|----------------|
|
|
15
|
+
| React | `@hugeicons/react` |
|
|
16
|
+
| React Native | `@hugeicons/react-native` |
|
|
17
|
+
| Vue | `@hugeicons/vue` |
|
|
18
|
+
| Angular | `@hugeicons/angular` |
|
|
19
|
+
| Svelte | `@hugeicons/svelte` |
|
|
10
20
|
|
|
11
21
|
### Key Highlights
|
|
12
|
-
|
|
13
|
-
- **
|
|
14
|
-
- **
|
|
15
|
-
- **
|
|
16
|
-
- **
|
|
22
|
+
|
|
23
|
+
- **4,600+ Free Icons**: Stroke Rounded set across 59 categories for unlimited personal and commercial projects
|
|
24
|
+
- **46,000+ Pro Icons, 10 Styles**: Stroke, Solid, Bulk, Duotone, and Twotone families for sharp, rounded, and standard needs
|
|
25
|
+
- **Pixel Perfect Grid**: Built on a 24x24 grid for crisp rendering at any size
|
|
26
|
+
- **Tree Shaking Ready**: Named exports keep bundles lean in modern bundlers
|
|
27
|
+
- **TypeScript Support**: Full type definitions included
|
|
17
28
|
- **Regular Updates**: New icons added regularly to keep up with evolving design trends
|
|
18
29
|
|
|
19
|
-
>
|
|
30
|
+
> **Looking for Pro Icons?** Check out our docs at [hugeicons.com/docs](https://hugeicons.com/docs) for detailed information about pro icons, styles, and advanced usage.
|
|
20
31
|
|
|
21
|
-

|
|
22
33
|
|
|
23
34
|
## Installation
|
|
24
35
|
|
|
25
|
-
|
|
36
|
+
You must install both this core package AND the wrapper for your framework:
|
|
26
37
|
|
|
27
38
|
```bash
|
|
28
|
-
#
|
|
29
|
-
npm install @hugeicons/core-free-icons
|
|
30
|
-
|
|
31
|
-
#
|
|
32
|
-
npm install @hugeicons/react
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
#
|
|
38
|
-
npm install @hugeicons/angular
|
|
39
|
-
|
|
40
|
-
|
|
39
|
+
# React
|
|
40
|
+
npm install @hugeicons/react @hugeicons/core-free-icons
|
|
41
|
+
|
|
42
|
+
# React Native
|
|
43
|
+
npm install @hugeicons/react-native @hugeicons/core-free-icons
|
|
44
|
+
|
|
45
|
+
# Vue
|
|
46
|
+
npm install @hugeicons/vue @hugeicons/core-free-icons
|
|
47
|
+
|
|
48
|
+
# Angular
|
|
49
|
+
npm install @hugeicons/angular @hugeicons/core-free-icons
|
|
50
|
+
|
|
51
|
+
# Svelte
|
|
52
|
+
npm install @hugeicons/svelte @hugeicons/core-free-icons
|
|
41
53
|
```
|
|
42
54
|
|
|
43
55
|
## Usage
|
|
44
56
|
|
|
57
|
+
### React Example
|
|
58
|
+
|
|
59
|
+
```jsx
|
|
60
|
+
import { HugeiconsIcon } from '@hugeicons/react';
|
|
61
|
+
import { SearchIcon } from '@hugeicons/core-free-icons';
|
|
62
|
+
|
|
63
|
+
function App() {
|
|
64
|
+
return (
|
|
65
|
+
<HugeiconsIcon
|
|
66
|
+
icon={SearchIcon}
|
|
67
|
+
size={24}
|
|
68
|
+
color="currentColor"
|
|
69
|
+
/>
|
|
70
|
+
);
|
|
71
|
+
}
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
### Vue Example
|
|
75
|
+
|
|
76
|
+
```vue
|
|
77
|
+
<template>
|
|
78
|
+
<HugeiconsIcon :icon="SearchIcon" :size="24" />
|
|
79
|
+
</template>
|
|
80
|
+
|
|
81
|
+
<script setup>
|
|
82
|
+
import { HugeiconsIcon } from '@hugeicons/vue';
|
|
83
|
+
import { SearchIcon } from '@hugeicons/core-free-icons';
|
|
84
|
+
</script>
|
|
85
|
+
```
|
|
86
|
+
|
|
45
87
|
### Import Methods
|
|
46
88
|
|
|
47
89
|
This package now supports multiple import methods for maximum flexibility:
|
|
48
90
|
|
|
49
91
|
#### 1. Static Import (Tree-shakeable)
|
|
92
|
+
|
|
50
93
|
Best for production builds when you know which icons you need:
|
|
51
94
|
|
|
52
95
|
```javascript
|
|
@@ -54,13 +97,15 @@ import { Home01Icon, User01Icon } from '@hugeicons/core-free-icons';
|
|
|
54
97
|
```
|
|
55
98
|
|
|
56
99
|
#### 2. Dynamic Import - Full Bundle
|
|
100
|
+
|
|
57
101
|
Loads the entire icon library (use when you need many icons dynamically):
|
|
58
102
|
|
|
59
103
|
```javascript
|
|
60
104
|
const { Home01Icon } = await import('@hugeicons/core-free-icons');
|
|
61
105
|
```
|
|
62
106
|
|
|
63
|
-
#### 3. Dynamic Import - Individual Icons
|
|
107
|
+
#### 3. Dynamic Import - Individual Icons
|
|
108
|
+
|
|
64
109
|
Loads only the specific icon you need (99% smaller bundle size):
|
|
65
110
|
|
|
66
111
|
```javascript
|
|
@@ -91,27 +136,28 @@ import { UserIcon, HomeIcon } from '@hugeicons/core-free-icons';
|
|
|
91
136
|
// Result: Only UserIcon and HomeIcon (~1.5KB) instead of entire library (~5MB)
|
|
92
137
|
```
|
|
93
138
|
|
|
94
|
-
**Requirements for tree-shaking:**
|
|
95
|
-
- Use a modern bundler (Webpack 5+, Rollup, Vite, Parcel)
|
|
96
|
-
- Ensure your bundler has tree-shaking enabled
|
|
97
|
-
- The package automatically sets `sideEffects: false` for optimal tree-shaking
|
|
139
|
+
- **Requirements for tree-shaking:**
|
|
140
|
+
- Use a modern bundler (Webpack 5+, Rollup, Vite, Parcel)
|
|
141
|
+
- Ensure your bundler has tree-shaking enabled
|
|
142
|
+
- The package automatically sets `sideEffects: false` for optimal tree-shaking
|
|
98
143
|
|
|
99
144
|
## Features
|
|
100
145
|
|
|
101
|
-
-
|
|
102
|
-
-
|
|
103
|
-
-
|
|
104
|
-
-
|
|
105
|
-
-
|
|
106
|
-
-
|
|
107
|
-
-
|
|
108
|
-
-
|
|
109
|
-
-
|
|
110
|
-
-
|
|
146
|
+
- **Individual Icon Imports**: Load only what you need with 99% bundle size reduction
|
|
147
|
+
- **Tree-shakeable**: Optimized for modern bundlers
|
|
148
|
+
- **Multiple Import Methods**: Static, dynamic bundle, or dynamic individual
|
|
149
|
+
- **TypeScript Support**: Full type definitions included
|
|
150
|
+
- **Framework Agnostic**: Works with any JavaScript framework
|
|
151
|
+
- **Optimized Performance**: Lazy load icons on demand
|
|
152
|
+
- **Customizable**: Easy to style with CSS or inline styles
|
|
153
|
+
- **ESM & CommonJS**: Support for both module systems
|
|
154
|
+
- **Zero Dependencies**: No external dependencies
|
|
155
|
+
- **Regular Updates**: New icons added frequently
|
|
111
156
|
|
|
112
157
|
## Framework Support
|
|
113
158
|
|
|
114
159
|
Hugeicons provides dedicated packages for various frameworks:
|
|
160
|
+
|
|
115
161
|
- [@hugeicons/react](https://www.npmjs.com/package/@hugeicons/react) - For React applications
|
|
116
162
|
- [@hugeicons/react-native](https://www.npmjs.com/package/@hugeicons/react-native) - For React Native applications
|
|
117
163
|
- [@hugeicons/vue](https://www.npmjs.com/package/@hugeicons/vue) - For Vue applications
|
|
@@ -126,4 +172,4 @@ TypeScript types are included and will work out of the box.
|
|
|
126
172
|
|
|
127
173
|
## License
|
|
128
174
|
|
|
129
|
-
Created by Hugeicons. All rights reserved.
|
|
175
|
+
Created by Hugeicons. All rights reserved.
|