Unicon CLI
Search and bundle icons from 9 libraries via command line. Define your icon sets once, regenerate anytime with a single command.
Installation
npm install -g @webrenew/uniconOr use directly with npx:
npx @webrenew/unicon search "dashboard"Commands
unicon search <query>Search for icons by name, keyword, or concept. Uses AI-powered semantic search for better results.
unicon search "settings gear"
unicon search "dashboard" --category Dashboards
unicon search "arrow" --source lucide --limit 10unicon get <name>Get a single icon and output to stdout. Perfect for piping to clipboard or a file.
unicon get home
unicon get home --format vue
unicon get settings --format svelte -o ./settings.svelteunicon info <name>Show detailed information about an icon including source, category, tags, and viewBox.
unicon info home
unicon info arrow-right --source phosphorunicon bundleBundle icons into tree-shakeable components. Creates one file per icon by default for optimal bundling.
unicon bundle --category Dashboards -o ./icons
unicon bundle --query "home" --format vue -o ./icons
unicon bundle --format svg --single-file -o ./all.svgunicon initInitialize a .uniconrc.json config file in your project with example bundle configurations.
unicon init
unicon init --force # Overwrite existingunicon syncGenerate all bundles defined in your .uniconrc.json config file.
unicon sync
unicon sync --name dashboard # Sync specific bundle
unicon sync --dry-run # Preview changesunicon add <name>Add a new bundle configuration to your .uniconrc.json file.
unicon add social --category Social
unicon add nav --query "arrow menu" --limit 30
unicon add files --source lucide --format vueunicon categoriesList all available icon categories.
unicon categories
unicon categories --jsonunicon preview <name>Show ASCII art preview of an icon directly in the terminal.
unicon preview home
unicon preview star --width 24 --height 24
unicon preview arrow --source phosphorunicon sourcesList all 8 available icon libraries with version info and icon counts.
unicon sources
unicon sources --jsonunicon cacheManage local cache for offline use. Icons are cached for 24 hours.
unicon cache --stats # Show cache info
unicon cache --clear # Clear all cached dataTypical Workflow
Initialize config
unicon initSearch for icons you need
unicon search "dashboard"Add bundles to your config
unicon add dashboard --category DashboardsGenerate all bundles
unicon syncImport and use
import { Home, Settings } from "./icons/dashboard"Config File
Define your icon bundles in .uniconrc.json and regenerate them anytime with unicon sync.
{
"bundles": [
{
"name": "dashboard",
"category": "Dashboards",
"limit": 50,
"format": "react",
"output": "./src/icons/dashboard.tsx"
},
{
"name": "navigation",
"query": "arrow chevron menu home",
"limit": 30,
"format": "react",
"output": "./src/icons/navigation.tsx"
},
{
"name": "social",
"category": "Social",
"source": "phosphor",
"format": "svg",
"output": "./public/icons/social.svg"
}
]
}Output Formats
react
TypeScript React components.
.tsxvue
Vue 3 SFC components.
.vuesvelte
Svelte components.
.sveltesvg
Raw SVG markup.
.svgjson
Icon data as JSON.
.jsonIcon Sources
Access 19,000+ icons from 9 popular icon libraries:
lucide
1,456 icons
phosphor
7,488 icons
hugeicons
3,000+ icons
heroicons
292 icons
tabler
3,000+ icons
feather
287 icons
remix
2,000+ icons
simple-icons
2,000+ brand logos
iconoir
1,600+ icons
AI Assistant Integration
NEWUse Unicon with Claude & Cursor
Connect Unicon to AI assistants via Model Context Protocol (MCP). Search and generate icon components using natural language.
Install the MCP server:
npx @webrenew/unicon-mcp-serverAdd to Claude Desktop config:
{
"mcpServers": {
"unicon": {
"command": "npx",
"args": ["-y", "@webrenew/unicon-mcp-server"]
}
}
}Then ask Claude:
Tree-Shaking
Unlike npm install lucide-react which downloads thousands of icons, the CLI generates only the icons you need as individual files.
import { Home } from "./icons"Offline Support
The CLI automatically caches icon data locally at ~/.unicon/cache for 24 hours. This enables faster subsequent searches and partial offline usage.
Ready to bundle some icons?
npx @webrenew/unicon init