File size: 845 Bytes
1e92f2d |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 |
---
title: Icon
description: Used to display an svg icon
links:
source: components/icon
storybook: components-icon--basic
---
<ExampleTabs name="icon-basic" />
## Usage
```jsx
import { Icon } from "@chakra-ui/react"
```
```jsx
<Icon />
```
:::warning
Chakra doesn't provide any icons out of the box. Use popular icon libraries like
[react-icons](https://react-icons.github.io/react-icons/) or
[lucide-react](https://lucide.dev/react/)
:::
## Examples
### React Icons
Integrate with popular react icon libraries like `react-icons`
<ExampleTabs name="icon-with-react-icon" />
### Custom svg
Use the `asChild` prop to render custom svg icons within the `Icon` component
<ExampleTabs name="icon-with-custom-svg" />
### Create Icon
Use the `createIcon` utility to create custom icons
<ExampleTabs name="icon-with-create-icon" />
|