Registry / orm / nicolaslopezj-searchable

nicolaslopezj-searchable

JSON →
library1.13.0phppackagistunverified

Eloquent model search trait.

composer require nicolaslopezj/searchable
INSTALL
IMPORT
SIG · NICOLASLOPEZJ-SEAR
N
nicolaslopezj-searchable
ormphpv1.13.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

SearchableTrait
use Nicolaslopezj\Searchable\SearchableTrait;

Add search functionality to an Eloquent model.

use Nicolaslopezj\Searchable\SearchableTrait; class User extends \Illuminate\Database\Eloquent\Model { use SearchableTrait; protected $searchable = ['columns' => ['name' => 10]]; } $users = User::search('John')->get();
Debug
Known issues
gotchaOnly works with Laravel Eloquent ORM.
fix
Ensure your project uses Laravel or Eloquent standalone.
affects: *
Upgrade
Version history
1.13.0latest on Packagist
Audit
Dependencies

No dependency data recorded yet.

Agent activity
39 hits · last 30 days
node
36
OpenAI (training)
1
Resources
nicolaslopezj-searchable — pip install nicolaslopezj-searchable · libregistry