Best laravel framework open-source packages.

Laravel builder macros

Laravel builder macros for the Eloquent ORM
Updated 2 years ago

Laravel Builder Macros

Usage

orderByRandom

User::orderByRandom()->first();
User::where...->orderByRandom()->get();

Installation

Add the Kevinsimard\BuilderMacros\Providers\OrderByRandomServiceProvider service provider in config/app.php.

Code Structure

├── src
│   └── Providers
│       └── OrderByRandomServiceProvider.php
├── .editorconfig
├── .gitattributes
├── .gitignore
├── LICENSE.md
├── README.md
└── composer.json

License

This package is open-sourced software licensed under the MIT license.