regnilk / fa-laravel
Laravel component for FontAwesome integration with Blade
1.1.4
2020-12-15 20:53 UTC
Requires
- php: >=7.2
- illuminate/config: ^7.0|^8.0
- illuminate/support: ^7.0|^8.0
README
Laravel component for FontAwesome integration with Blade
Note : This package is to be used with Laravel version 8
Installation
Install the package via Composer:
$ composer require regnilk/fa-laravel
The package service provider will be registered automatically.
Configuration
You need to publish the configuration file to set the icons you need
php artisan vendor:publish --provider="Regnilk\FaLaravel\FaServiceProvider"
Then edit the array returned in app/config/fa-laravel.php this way :
return [ "ok" => "fas fa-check", "close" => "fas fa-times" ];
It will provide you a dictionary of icons shortcuts.
Usage
To display an icon, just call it this way :
<x-fa icon="ok" />
You can customize this component like any other :
<x-fa icon="close" class="text-danger" style="font-weight: bold;" title="Click here to close" />
Contact
Please use GitHub for making comments or suggestions or to report bugs.
License
Fa-Laravel written by Regnilk and released under the MIT License.
Copyright
Copyright © 2020 Regnilk