PHPackages                             osamaalmamri/laravel-search - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Search &amp; Filtering](/categories/search)
4. /
5. osamaalmamri/laravel-search

ActiveLibrary[Search &amp; Filtering](/categories/search)

osamaalmamri/laravel-search
===========================

This is my package laravel-search

1.0(2y ago)742[2 PRs](https://github.com/OsamaAlmamri/laravel-search/pulls)MITPHPPHP ^8.0

Since Sep 7Pushed 2y ago1 watchersCompare

[ Source](https://github.com/OsamaAlmamri/laravel-search)[ Packagist](https://packagist.org/packages/osamaalmamri/laravel-search)[ Docs](https://github.com/osamaalmamri/laravel-search)[ RSS](/packages/osamaalmamri-laravel-search/feed)WikiDiscussions master Synced today

READMEChangelog (1)Dependencies (5)Versions (4)Used By (0)

package laravel-search
======================

[](#package-laravel-search)

[![Latest Version on Packagist](https://camo.githubusercontent.com/0f677e0d992bd586e45c0d75c343688b4338c9625e2d766af60ddc9df4f0b372/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6f73616d61616c6d616d72692f6c61726176656c2d7365617263682e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/osamaalmamri/laravel-search)[![GitHub Tests Action Status](https://camo.githubusercontent.com/ec14f35bf2df0a910cae4dcc942214fa824286d581f3b31057f81313acbceee2/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6f73616d61616c6d616d72692f6c61726176656c2d7365617263682f72756e2d74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/osamaalmamri/laravel-search/actions?query=workflow%3Arun-tests+branch%3Amain)[![GitHub Code Style Action Status](https://camo.githubusercontent.com/d76e7bcb169ab570d2fa6f1ecd28d092bf65cf69ccadef254a3f44ca639af62a/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6f73616d61616c6d616d72692f6c61726176656c2d7365617263682f6669782d7068702d636f64652d7374796c652d6973737565732e796d6c3f6272616e63683d6d61696e266c6162656c3d636f64652532307374796c65267374796c653d666c61742d737175617265)](https://github.com/osamaalmamri/laravel-search/actions?query=workflow%3A%22Fix+PHP+code+style+issues%22+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/6a46ccd58c63a8568d02b212ab95ab5bb3df9ce53cea929c2bdfbe46aa24f581/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6f73616d61616c6d616d72692f6c61726176656c2d7365617263682e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/osamaalmamri/laravel-search)

this package is facility the search in model with complex relations

Installation
------------

[](#installation)

You can install the package via composer:

```
composer require osamaalmamri/laravel-search
```

You can publish the config file with:

```
php artisan vendor:publish --tag="laravel-search-config"
```

This is the contents of the published config file:

```
return [

// this is the key namein Request $request
 'key' => "search"
];
```

Usage
-----

[](#usage)

in the modal we use searchable class

```
use OsamaAlmamri\LaravelSearch\Searchable;

class YourModal extends Model
{
  use Searchable;

  // define the name of cols
  //if you need search in another fields of another table using the relation name then col name
  // you can search any  related relation as the following
      public $searchable = ['name','description','user.name','user.phone','user.role.name'];
}
```

Credits
-------

[](#credits)

- [Osama Al-mamari](https://github.com/OsamaAlmamri)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

25

—

LowBetter than 35% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity51

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

1030d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/43526628?v=4)[Osama Al-mamari ](/maintainers/OsamaAlmamri)[@OsamaAlmamri](https://github.com/OsamaAlmamri)

---

Top Contributors

[![OsamaAlmamri](https://avatars.githubusercontent.com/u/43526628?v=4)](https://github.com/OsamaAlmamri "OsamaAlmamri (1 commits)")

---

Tags

laravellaravel-searchOsamaAlmamri

### Embed Badge

![Health badge](/badges/osamaalmamri-laravel-search/health.svg)

```
[![Health](https://phpackages.com/badges/osamaalmamri-laravel-search/health.svg)](https://phpackages.com/packages/osamaalmamri-laravel-search)
```

###  Alternatives

[spatie/laravel-medialibrary

Associate files with Eloquent models

6.1k43.2M631](/packages/spatie-laravel-medialibrary)[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M345](/packages/psalm-plugin-laravel)[spatie/laravel-health

Monitor the health of a Laravel application

87512.0M164](/packages/spatie-laravel-health)[yajra/laravel-oci8

Oracle DB driver for Laravel via OCI8

8793.2M25](/packages/yajra-laravel-oci8)[simplestats-io/laravel-client

Server-side analytics for Laravel that follows the full funnel from visit to registration to payment, attributed to the channel that drove it. Revenue, MRR, churn and ad-spend profit (ROAS/CAC) per channel. GDPR compliant, ad-blocker proof.

5021.9k](/packages/simplestats-io-laravel-client)[api-platform/laravel

API Platform support for Laravel

58171.5k14](/packages/api-platform-laravel)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
