iconify-search
v0.0.1
Published
A command-line client for the [Iconify API](https://iconify.design/docs/api/), built with TypeScript and Bun.
Readme
iconify-search
A command-line client for the Iconify API, built with TypeScript and Bun.
Browse and search 200k+ open-source icons, and build SVG URLs with transformations applied — straight from the terminal.
Install
bun installRun via Bun:
bun run index.ts <command> [options]Or link it as iconify-search:
bun link
iconify-search <command> [options]Commands
Icons are referenced as prefix:name (e.g. mdi:home), matching Iconify's own convention.
Structured output (search, collections, list) is rendered as TOON by default — compact and readable. Pass --json for raw JSON.
url <prefix:name>
Build an SVG URL for an icon, with optional transformations.
iconify-search url mdi:home
iconify-search url mdi:home --color '#ba3329' --width 24
iconify-search url mdi:home --rotate 90deg --flip horizontal --boxOptions: --color, --width, --height, --flip, --rotate, --box, --download.
search <query>
Search icons across all icon sets.
iconify-search search home
iconify-search search arrow --limit 999 --prefixes mdi-,biOptions: --limit, --prefix, --prefixes, --category, --json.
collections
List available icon sets.
iconify-search collections
iconify-search collections --prefixes fa,biOptions: --prefix, --prefixes, --json.
list <prefix>
List the icon names within an icon set.
iconify-search list mdi-lightOptions: --info, --chars, --json.
Development
bun test # run the test suite
bunx tsc --noEmit # typecheckThe codebase separates pure logic from I/O:
src/api.ts— URL builders for every endpointsrc/icon-ref.ts—prefix:nameparsingsrc/transform.ts— reshaping API responses for outputsrc/output.ts— TOON / JSON formattingsrc/fetch.ts— the network boundarysrc/commands/*— command handlers (network injected for testability)src/cli.ts— argument parsing and dispatch
