@moamfar/icon-pack 1.0.0 → 1.0.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.
Files changed (3) hide show
  1. package/README.md +28 -12
  2. package/package.json +1 -1
  3. package/readme.js +30 -15
package/README.md CHANGED
@@ -1,6 +1,19 @@
1
1
  # @moamfar/icon-pack
2
2
 
3
- A collection of beautiful, weight-adjustable SVG icons.
3
+ ![npm version](https://badge.fury.io/js/@moamfar/icon-pack.svg)
4
+ ![npm downloads](https://img.shields.io/npm/dm/@moamfar/icon-pack.svg)
5
+ ![License](https://img.shields.io/npm/l/@moamfar/icon-pack.svg)
6
+ ![Typescript](https://img.shields.io/badge/TypeScript-5.0-blue)
7
+
8
+ A collection of beautiful, weight-adjustable SVG icons.
9
+
10
+ ## Features
11
+
12
+ * **🌳 Tree-shakable:** Only import the icons you use.
13
+ * **🎨 Customizable:** Control size, color, and weight (Outline/Bold) easily.
14
+ * **✨ TypeScript:** Built with full type safety support.
15
+ * **🛠 Framework Agnostic:** Works with React, Next.js, Vite, and CRA.
16
+ * **⚡ Zero Dependencies:** Lightweight footprint.
4
17
 
5
18
  ## Installation
6
19
 
@@ -20,18 +33,17 @@ yarn add @moamfar/icon-pack
20
33
  import { Dislike, Heart, HeartAngle } from "@moamfar/icon-pack";
21
34
 
22
35
  const App = () => {
23
- return (
24
- <div>
25
- <Dislike size={32} color="black" />
36
+ return (
37
+ <div>
38
+ <Dislike size={32} color="black" />
26
39
  <Heart size={32} color="blue" weight="bold" />
27
- <HeartAngle size={48} className="text-red-500" />
28
- </div>
29
- );
40
+ <HeartAngle size={48} className="text-red-500" />
41
+ </div>
42
+ );
30
43
  };
31
44
  ```
32
45
 
33
-
34
-
46
+
35
47
  <h3>Component Props</h3>
36
48
 
37
49
  <table style="border-collapse: collapse; width: 100%; min-width: 500px;">
@@ -77,8 +89,7 @@ return (
77
89
  There are currently **17** icons.
78
90
 
79
91
  <!-- Icons Grid Start -->
80
-
81
- <table style="border-collapse: collapse; width: 100%; min-width: 500px;">
92
+ <table style="border-collapse: collapse; width: 100%; min-width: 500px;">
82
93
  <thead>
83
94
  <tr style="border-bottom: 1px solid #ddd;">
84
95
  <th style="text-align: center; padding: 12px; width: 50px;">Preview</th>
@@ -144,9 +155,14 @@ There are currently **17** icons.
144
155
  </tr>
145
156
  </tbody>
146
157
  </table>
147
-
148
158
  <!-- Icons Grid End -->
149
159
 
160
+ ## Keywords
161
+
162
+ A collection of beautiful, weight-adjustable SVG icons.
163
+
164
+ react, icons, svg, components, ui, outline, bold, weight, typescript, tailwind, icon-library, design-system, free-icons
165
+
150
166
  ## License
151
167
 
152
168
  MIT
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moamfar/icon-pack",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "A collection of beautiful, weight-adjustable SVG icons.",
5
5
  "main": "./src/generated/index.js",
6
6
  "module": "./src/generated/index.js",
package/readme.js CHANGED
@@ -37,14 +37,13 @@ function getBase64Icon(componentName) {
37
37
  return `<img src="data:image/svg+xml;base64,${base64}" width="24" height="24" style="vertical-align: middle;" alt="${componentName}" />`;
38
38
  }
39
39
  }
40
- return "";
40
+ return `<code>${componentName}</code>`;
41
41
  }
42
42
 
43
43
  // 3. Generate HTML Table for Icons
44
44
  function generateIconList(components) {
45
45
  if (components.length === 0) return "No icons found.";
46
46
 
47
- // Using HTML ensures perfect alignment in VS Code
48
47
  let tableHTML = `<table style="border-collapse: collapse; width: 100%; min-width: 500px;">\n <thead>\n <tr style="border-bottom: 1px solid #ddd;">\n <th style="text-align: center; padding: 12px; width: 50px;">Preview</th>\n <th style="text-align: left; padding: 12px;">Name</th>\n <th style="text-align: center; padding: 12px; width: 50px;">Preview</th>\n <th style="text-align: left; padding: 12px;">Name</th>\n </tr>\n </thead>\n <tbody>\n`;
49
48
 
50
49
  for (let i = 0; i < components.length; i += 2) {
@@ -72,10 +71,9 @@ function generateIconList(components) {
72
71
  return tableHTML;
73
72
  }
74
73
 
75
- // 4. Generate HTML Table for Props
74
+ // 4. Generate Props Table
76
75
  function generatePropsTable() {
77
76
  return `
78
-
79
77
  <h3>Component Props</h3>
80
78
 
81
79
  <table style="border-collapse: collapse; width: 100%; min-width: 500px;">
@@ -138,7 +136,20 @@ try {
138
136
  // 3. Construct README Content
139
137
  const readmeContent = `# ${pkgName}
140
138
 
141
- ${pkgDesc}
139
+ ![npm version](https://badge.fury.io/js/${pkgName}.svg)
140
+ ![npm downloads](https://img.shields.io/npm/dm/${pkgName}.svg)
141
+ ![License](https://img.shields.io/npm/l/${pkgName}.svg)
142
+ ![Typescript](https://img.shields.io/badge/TypeScript-5.0-blue)
143
+
144
+ ${pkgDesc}
145
+
146
+ ## Features
147
+
148
+ * **🌳 Tree-shakable:** Only import the icons you use.
149
+ * **🎨 Customizable:** Control size, color, and weight (Outline/Bold) easily.
150
+ * **✨ TypeScript:** Built with full type safety support.
151
+ * **🛠 Framework Agnostic:** Works with React, Next.js, Vite, and CRA.
152
+ * **⚡ Zero Dependencies:** Lightweight footprint.
142
153
 
143
154
  ## Installation
144
155
 
@@ -158,27 +169,31 @@ yarn add ${pkgName}
158
169
  import { ${components.slice(0, 3).join(", ")} } from "${pkgName}";
159
170
 
160
171
  const App = () => {
161
- return (
162
- <div>
163
- <${components[0]} size={32} color="black" />
172
+ return (
173
+ <div>
174
+ <${components[0]} size={32} color="black" />
164
175
  <${components[1]} size={32} color="blue" weight="bold" />
165
- <${components[2]} size={48} className="text-red-500" />
166
- </div>
167
- );
176
+ <${components[2]} size={48} className="text-red-500" />
177
+ </div>
178
+ );
168
179
  };
169
180
  \`\`\`
170
181
 
171
- ${propsTableHTML}
182
+ ${propsTableHTML}
172
183
 
173
184
  ## Available Icons
174
185
 
175
186
  There are currently **${components.length}** icons.
176
187
 
177
188
  <!-- Icons Grid Start -->
189
+ ${iconListHTML}
190
+ <!-- Icons Grid End -->
178
191
 
179
- ${iconListHTML}
192
+ ## Keywords
180
193
 
181
- <!-- Icons Grid End -->
194
+ ${pkgDesc}
195
+
196
+ react, icons, svg, components, ui, outline, bold, weight, typescript, tailwind, icon-library, design-system, free-icons
182
197
 
183
198
  ## License
184
199
 
@@ -187,7 +202,7 @@ MIT
187
202
 
188
203
  // 4. Write to file
189
204
  fs.writeFileSync(readmeOutputPath, readmeContent);
190
- console.log(`✅ README.md generated successfully!`);
205
+ console.log(`✅ README.md generated successfully with SEO tags!`);
191
206
  } catch (error) {
192
207
  console.error("❌ Error generating README:", error);
193
208
  process.exit(1);