staudenmeir/eloquent-eager-limit-x-laravel-cte

Merge of staudenmeir/eloquent-eager-limit and staudenmeir/laravel-cte

v1.1.1 2023-02-12 22:42 UTC

This package is auto-updated.

Last update: 2024-10-09 14:09:46 UTC


README

CI Code Coverage Scrutinizer Code Quality Latest Stable Version Total Downloads License

Important

The staudenmeir/eloquent-eager-limit package's code has been merged into Laravel 11+ and eager loading limits are now supported natively.

This Laravel package merges staudenmeir/eloquent-eager-limit and staudenmeir/laravel-cte to allow them being used in the same model.

Supports Laravel 9–10.

Installation

composer require staudenmeir/eloquent-eager-limit-x-laravel-cte:"^1.0"

Use this command if you are in PowerShell on Windows (e.g. in VS Code):

composer require staudenmeir/eloquent-eager-limit-x-laravel-cte:"^^^^1.0"

Versions

Usage

Use the HasEagerLimitAndQueriesExpressions trait in your model:

class User extends Model
{
    use \Staudenmeir\EloquentEagerLimitXLaravelCte\Eloquent\HasEagerLimitAndQueriesExpressions;
}

Contributing

Please see CONTRIBUTING and CODE OF CONDUCT for details.