Skip to content

Commit 4e41ff6

Browse files
committed
Update index.mdx to use React icons for Cards
- Refactor feature cards to use `<Feather />`, `<ShieldCheck />`, and other React-based icons from `lucide-react` for improved alignment and consistency. - Minor enhancements to example code blocks for readability and clarity.
1 parent 12498f3 commit 4e41ff6

File tree

1 file changed

+11
-6
lines changed

1 file changed

+11
-6
lines changed

web/content/docs/index.mdx

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ description: Learn about fast-url - a high-performance URL building library that
66
import { Callout } from 'fumadocs-ui/components/callout';
77
import { Cards, Card } from 'fumadocs-ui/components/card';
88
import { Tab, Tabs } from 'fumadocs-ui/components/tabs';
9+
import { Feather, ShieldCheck, Lock, Globe, Wrench, Zap } from 'lucide-react';
910

1011
# Introduction
1112

@@ -59,27 +60,27 @@ The original [urlcat](https://github.com/balazsbotond/urlcat) library is a solid
5960
## Key Features
6061

6162
<Cards>
62-
<Card title="Lightweight" icon="feather">
63+
<Card title="Lightweight" icon={<Feather />}>
6364
Only one dependency (fast-querystring) with minimal bundle size - perfect
6465
for performance-critical applications
6566
</Card>
66-
<Card title="Type Safe" icon="shield-check">
67+
<Card title="Type Safe" icon={<ShieldCheck />}>
6768
Written in TypeScript with full type definitions for better development
6869
experience and compile-time safety
6970
</Card>
70-
<Card title="URL Safe" icon="lock">
71+
<Card title="URL Safe" icon={<Lock />}>
7172
Automatically escapes parameters and handles edge cases - no more broken
7273
URLs from special characters
7374
</Card>
74-
<Card title="Unicode-aware" icon="globe">
75+
<Card title="Unicode-aware" icon={<Globe />}>
7576
Uses `codePointAt` for proper Unicode handling, including graceful encoding
7677
of lone surrogates and emojis
7778
</Card>
78-
<Card title="Flexible" icon="wrench">
79+
<Card title="Flexible" icon={<Wrench />}>
7980
Multiple ways to build URLs for different use cases - from simple
8081
concatenation to complex path and query parameters
8182
</Card>
82-
<Card title="High Performance" icon="zap">
83+
<Card title="High Performance" icon={<Zap />}>
8384
Optimized for speed with benchmarks showing significant improvements over
8485
the original implementation
8586
</Card>
@@ -92,6 +93,8 @@ Building URLs manually is error-prone and difficult to maintain:
9293
```javascript
9394
// ❌ Error-prone manual approach
9495
const url = `${baseUrl}/users/${id}/posts?limit=${limit}&offset=${offset}`;
96+
97+
await fetch(url);
9598
```
9699

97100
**Issues with manual URL building:**
@@ -111,6 +114,8 @@ fast-url provides a clean, safe API for URL construction:
111114
import createUrl from 'fast-url';
112115

113116
const url = createUrl(baseUrl, '/users/:id/posts', { id, limit, offset });
117+
118+
await fetch(url);
114119
```
115120

116121
**Benefits:**

0 commit comments

Comments
 (0)