codeiucom / laravel-blade-svg-icons
CodeIU Laravel Blade Svg Icons Directive
Installs: 5
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
Type:framework
Requires
- php: ^8.0
This package is auto-updated.
Last update: 2025-03-29 01:03:25 UTC
README
install
composer require codeiucom/laravel-blade-svg-icons
use directive
- Heroicons
- ex) @heroicons-
iconName
-style
("classes
")
- default
@heroicons-folder("w-6 h-6") <!-- or --> <heroicons-folder class="w-6 h-6"/> <!-- or --> <heroicons-folder class="w-6 h-6"></heroicons-folder>
- outline
@heroicons-folder-o("w-6 h-6") <!-- or --> <heroicons-folder-o class="w-6 h-6"/> <!-- or --> <heroicons-folder-o class="w-6 h-6"></heroicons-folder-o>
- solid
@heroicons-folder-s("w-6 h-6") <!-- or --> <heroicons-folder-s class="w-6 h-6"/> <!-- or --> <heroicons-folder-s class="w-6 h-6"></heroicons-folder-s>
- Bootstrap Icons
- ex) @twbsicons-
iconName
("classes
")@twbsicons-github("w-5 h-5") <!-- or --> <twbsicons-github class="w-5 h-5"/>
Heroicons options
-
change directive ex)
# default heroicons CODEIU_LARAVEL_BLADE_SVG_HEROICONS_PREFIX=hicon # default twbsicons CODEIU_LARAVEL_BLADE_SVG_TWBS_ICONS_PREFIX=bsicon
-
set default class ex)
# default empty CODEIU_LARAVEL_BLADE_SVG_HEROICONS_DEFAULT_CLASSES="w-6 h-6" # default empty CODEIU_LARAVEL_BLADE_SVG_TWBSICONS_DEFAULT_CLASSES="w-5 h-5"
if you use default class with tailwindcss, add below in tailwind.config.js
module.exports = { ... content: [ './storage/framework/views/*.php', ], ... }
-
change heroicons default style (default: solid)
CODEIU_LARAVEL_SVG_BLADE_HEROICONS_DEFAULT_STYLE=outline
svg icons
heroicons - v1.0.5
https://github.com/tailwindlabs/heroicons
twbs icons - v1.8.1
https://github.com/twbs/icons