abduns/hugeicons-flux
Use Hugeicons as native Flux UI Blade components (flux:icon.hugeicons.*). Includes 5,100+ free Stroke Rounded icons, optional generation of all 9 Pro styles from your own license, modern PHP support, and a Laravel Boost Agent Skill for AI workflows.
Use any Hugeicons icon as a native flux:icon.hugeicons.* component in Flux UI — the free Stroke Rounded set bundled, or generate all 9 Pro styles from your own Hugeicons licence.
composer require abduns/hugeicons-flux
// Use it directly in your Blade views
Example output:
<flux:icon.hugeicons.home-01 class="size-8" />
This package ships a Laravel Boost Agent Skill at:
resources/boost/skills/hugeicons-flux/SKILL.md
Laravel Boost can discover it during boost:install or boost:update --discover.
If you want to publish the skill into your application's .ai/skills directory
for customization, run:
php artisan hugeicons:boost-skill
Use --force to replace an existing local copy.
This package focuses on simplicity, interoperability, and modern developer ergonomics to integrate Hugeicons into Laravel Flux UI effortlessly.
Every icon is flux:icon.hugeicons.{name}, where {name} is the kebab-case
Hugeicons name (Home01Icon → home-01, AiSearch02Icon → ai-search-02).
{{-- Default --}}
<flux:icon.hugeicons.home-01 />
{{-- Sizing & colour — like any Flux icon --}}
<flux:icon.hugeicons.home-01 class="size-10 text-blue-500" />
{{-- As an `icon` prop on other Flux components --}}
<flux:button icon="hugeicons.calendar-03" />
<flux:navlist.item icon="hugeicons.dashboard-square-01">Dashboard</flux:navlist.item>
The variant prop accepts the real Hugeicons style names, plus Flux's own
outline / solid / mini / micro as aliases:
<flux:icon.hugeicons.search-01 variant="solid-rounded" class="size-8 text-amber-500" />
variant |
Resolves to |
|---|---|
outline (default), mini, micro, stroke, stroke-rounded |
stroke-rounded |
solid, solid-rounded |
solid-rounded |
bulk-rounded, duotone-rounded, twotone-rounded, *-sharp, … |
the matching Hugeicons style |
If an icon has not been built with a requested style (e.g. you only have the
free set), the variant gracefully falls back to stroke-rounded.
To use Pro icon styles you need to:
.npmrc).npmrc.npmrc is a plain-text config file that npm reads before installing packages.
Create (or open) a file called .npmrc in the root of your project (same folder as package.json) and add these two lines:
@hugeicons-pro:registry=https://npm.hugeicons.com/
//npm.hugeicons.com/:_authToken=${HUGEICONS_PRO_LICENSE_KEY}
What this does
- Line 1 tells npm to fetch every
@hugeicons-pro/*package from the Hugeicons registry instead of the public npm registry.- Line 2 authenticates you with your licence key. The
${HUGEICONS_PRO_LICENSE_KEY}placeholder is replaced automatically by npm using the environment variable of the same name — you never hard-code your key in this file.
Tip — commit
.npmrc, never your key It is safe (and recommended) to commit.npmrcto version control because it contains no secrets — only the${…}placeholder. Your actual key lives only in the environment.
HUGEICONS_PRO_LICENSE_KEY environment variableYour licence key is available in your Hugeicons dashboard.
Choose the method that fits your workflow:
macOS / Linux — current terminal session
export HUGEICONS_PRO_LICENSE_KEY="your-licence-key-here"
Run this once per terminal session before you run npm install. The key is gone when you close the tab.
macOS / Linux — permanent (shell profile)
Add the export line to your shell config so it is always available:
# ~/.zshrc (zsh, default on modern macOS)
# ~/.bashrc (bash)
echo 'export HUGEICONS_PRO_LICENSE_KEY="your-licence-key-here"' >> ~/.zshrc
source ~/.zshrc
Windows — PowerShell (current session)
$env:HUGEICONS_PRO_LICENSE_KEY = "your-licence-key-here"
Windows — permanent (System Environment Variables)
HUGEICONS_PRO_LICENSE_KEYyour-licence-key-hereCI / CD (GitHub Actions, etc.)
Store the key as a repository secret (e.g. HUGEICONS_PRO_LICENSE_KEY) and expose it as an environment variable in your workflow:
- name: Install dependencies
run: npm ci
env:
HUGEICONS_PRO_LICENSE_KEY: ${{ secrets.HUGEICONS_PRO_LICENSE_KEY }}
.env file (Laravel)
If you prefer keeping all project secrets in one place, add it to your Laravel .env file:
HUGEICONS_PRO_LICENSE_KEY=your-licence-key-here
Then export it for npm by running:
export HUGEICONS_PRO_LICENSE_KEY="$(grep HUGEICONS_PRO_LICENSE_KEY .env | cut -d '=' -f2)"
Never commit
.env— it is already in.gitignoreby default in Laravel projects.
With .npmrc in place and the environment variable set, run:
npm install --save-optional \
@hugeicons-pro/core-stroke-rounded \
@hugeicons-pro/core-solid-rounded
php artisan hugeicons:build
Available Pro packages (install only the styles you need):
| Package | Style |
|---|---|
@hugeicons-pro/core-stroke-rounded |
Stroke Rounded |
@hugeicons-pro/core-solid-rounded |
Solid Rounded |
@hugeicons-pro/core-bulk-rounded |
Bulk Rounded |
@hugeicons-pro/core-duotone-rounded |
Duotone Rounded |
@hugeicons-pro/core-twotone-rounded |
Twotone Rounded |
After hugeicons:build completes, the generated Blade components are ready to use via the variant prop.
References:
| Feature | Support |
|---|---|
| Free Stroke Rounded Set | ✅ |
| Pro Styles Generator | ✅ |
| Laravel Boost Agent Skill | ✅ |
| Claude Code Skill | ✅ |
| Platform | Supported |
|---|---|
| PHP 8.2+ | ✅ |
| Laravel 11.0+ | ✅ |
| Flux UI 2 | ✅ |
| Operation | Time |
|---|---|
| Render component | < 1ms |
composer test
Contributions, issues, and discussions are welcome.
If you discover security issues, please report them responsibly.
MIT
How can I help you explore Laravel packages today?