andach / laravel-primary-key-uuid
This is an incredibly simple package to add a simple trait for Laravel models where the primary key is a UUID.
Installs: 685
Dependents: 2
Suggesters: 0
Security: 0
Stars: 0
Watchers: 0
Forks: 0
Open Issues: 0
pkg:composer/andach/laravel-primary-key-uuid
Requires
- php: ^8.1
- illuminate/contracts: ^10.0
- spatie/laravel-package-tools: ^1.14.0
Requires (Dev)
- laravel/pint: ^1.0
- nunomaduro/collision: ^7.8
- orchestra/testbench: ^8.8
- phpunit/phpunit: ^10.0
README
This is an incredibly simple package to add a simple trait for Laravel models where the primary key is a UUID.
Installation
You can install the package via composer:
composer require andach/laravel-primary-key-uuid
There are no migrations, views or config file.
Usage
<?php namespace App\Models; use Andach\LaravelPrimaryKeyUuid\Traits\PrimaryKeyUUID; class MyModel extends Model { use PrimaryKeyUUID; // ... }
Testing
composer test
Credits
License
The MIT License (MIT). Please see License File for more information.