composer require crushjs/laravel-smart-filteruse Crushjs\SmartFilter\SmartFilter;
use App\Models\User;
$users = SmartFilter::apply(
User::query(),
request()->only(['name', 'email'])
)->get();Publish the configuration file using the following command:
php artisan vendor:publish --provider="Crushjs\SmartFilter\SmartFilterServiceProvider" --tag="config"- ✅ Support for query filtering
- ✅ Easy integration with Laravel applications
MIT © Crushjs