Configs2026年5月27日·1 分钟阅读

Heroicons — Beautiful Hand-Crafted SVG Icons by the Makers of Tailwind CSS

A set of free, MIT-licensed SVG icons designed by the Tailwind CSS team, available in outline, solid, and mini styles for use in web and mobile projects.

Agent 就绪

Agent 可直接安装

这个资产可安装;Agent 先选择当前运行时、检查安装计划,再运行匹配命令。

Native · 98/100策略:允许
Agent 入口
任意 MCP/CLI Agent
类型
Skill
安装
Single
信任
信任等级:Established
入口
Heroicons
直接安装命令
npx -y tokrepo@latest install 61586e04-59a5-11f1-9bc6-00163e2b0d79 --target codex

先 dry-run 确认安装计划,再运行此命令。

Introduction

Heroicons is a collection of free, MIT-licensed SVG icons designed by the team behind Tailwind CSS. Each icon is hand-crafted on a pixel grid to ensure clarity at common sizes. The set ships with first-party React and Vue components, plus raw SVGs that work anywhere.

What Heroicons Does

  • Provides 300+ icons in three variants: 24px outline, 24px solid, and 20px mini
  • Ships first-party React and Vue component libraries for tree-shakable imports
  • Exposes raw SVG files that can be used in any framework or design tool
  • Follows a consistent stroke width and visual weight across the entire set
  • Offers a searchable web catalog for browsing and copying icons instantly

Architecture Overview

The icon source files are hand-drawn SVGs organized by variant (outline, solid, mini) in the repository. A build pipeline processes these SVGs into optimized React and Vue component packages published to npm. Each component accepts standard SVG props such as className and aria-label, making them composable with any styling approach. The raw SVG files are also published as a standalone package for framework-agnostic use.

Self-Hosting & Configuration

  • Install the React package: npm install @heroicons/react
  • Install the Vue package: npm install @heroicons/vue
  • Import icons by size and style path, e.g. @heroicons/react/24/outline
  • Use raw SVGs from the heroicons npm package or copy from the repository
  • Customize color via CSS color property since icons use currentColor by default

Key Features

  • Designed on a strict pixel grid for crisp rendering at 20px and 24px
  • Three distinct styles (outline, solid, mini) for different UI contexts
  • Tree-shakable packages mean unused icons are excluded from your bundle
  • Every icon uses currentColor for seamless theming with CSS or Tailwind classes
  • MIT license allows unrestricted commercial and personal use

Comparison with Similar Tools

  • Lucide — community fork of Feather Icons with more icons; Heroicons is maintained by the Tailwind CSS team with a tighter design language
  • Feather Icons — minimalist outline-only set; Heroicons adds solid and mini variants
  • Phosphor Icons — large set with six weights; Heroicons focuses on three opinionated styles tuned for Tailwind
  • Material Symbols — Google's icon set with variable font support; Heroicons uses pure SVG with no font dependency
  • Radix Icons — small set tailored for Radix UI; Heroicons offers broader coverage and framework-agnostic SVGs

FAQ

Q: Can I use Heroicons without React or Vue? A: Yes. Install the heroicons npm package for raw SVGs, or copy them directly from the website or the GitHub repository.

Q: How do I change the icon color? A: Icons use currentColor, so set the CSS color property on the icon element or its parent.

Q: Are new icons added regularly? A: The set grows with periodic releases. Check the GitHub repository or heroicons.com for the latest additions.

Q: Is there a Figma file? A: Yes, the Tailwind CSS team provides an official Figma file for designers linked from the repository and website.

Sources

讨论

登录后参与讨论。
还没有评论,来写第一条吧。

相关资产