laravel-ulid icon indicating copy to clipboard operation
laravel-ulid copied to clipboard

Add ulid macro to Blueprint class

Open inDeev opened this issue 1 year ago • 0 comments

In migration just write $table->ulid('column_name') instead of $table->char('column_name', 26), so devs are not forced to remember that ulid is 26 characters long char type.

This PR is backward compatible, means $table->char('id', 26) will still work

To consider - as ULID is mentioned to be used as primary key, maybe it can be specified in macro instead of ->unique()

inDeev avatar Dec 16 '23 18:12 inDeev