Swarm Icons: a PHP library for rendering SVG icons without Node.js
Built a library that lets you pull from 200,000+ Iconify icons in pure PHP. Download the sets you want via CLI and render them with a helper function.
bash php bin/swarm-icons json:download heroicons tabler
php echo swarm_icon('heroicons:home', ['class' => 'w-6 h-6']);
Supports local SVG directories, the Iconify API, or JSON collections. Twig and Blade integrations, PSR-16 caching, sprite sheet support, and SVG sanitization are all included. Requires PHP 8.2+.
Docs: https://frostybee.github.io/swarm-icons/ GitHub: https://github.com/frostybee/swarm-icons
Still actively working on it, happy to take feedback.
[link] [comments]