rockbuzz/lara-uuid

Laravel Uuid

2.0.2 2023-02-17 19:29 UTC

README

Laravel Uuid

Requirements

PHP: >=7.3

Install

$ composer require rockbuzz/lara-uuid
Schema::create('workspaces', function (Blueprint $table) {
    $table->uuid('id')->primary();
    ...
});

use Rockbuzz\LaraUuid\Traits\UUid;
	
class User extends Authenticatable
{
    use Uuid;

    public $incrementing = false;

    protected $keyType = 'string';

    protected $casts = [
        'id' => 'string',
    ];

    ...
	    
}

License

The Lara Uuid is open-sourced software licensed under the MIT license.