brunocfalcao / blade-feather-icons

A package to easily make use of Feather Icons in your Laravel Blade views.
MIT License
34 stars 13 forks source link

Compatibility with dynamic components #44

Open rgr opened 1 year ago

rgr commented 1 year ago

Hi,

would it be possible to make this package compatible with laravel dynamic components (https://laravel.com/docs/8.x/blade#dynamic-components) so we can create components that generate icons on the fly like this ?

    <x-dynamic-component component="x-feathericon-{{ $icon }}"
        class="w-5 h-5 mr-3 -ml-1 @if(request()->routeIs($routeIs)) text-primary @else text-black @endif" />

Thanks for the update !

brunocfalcao commented 1 year ago

That's a good point, but I need to investigate how to do it, might take some time sorry.

If you know how to do it, then please kindly consider a PR and I will surely approve it.