DEV Community

Discussion on: Eloquent UUIDs.

Collapse
 
billriess profile image
Bill Riess

Instead of creating a UUIDv4, you should use:

Str::orderedUuid();

The helper is already provided by Laravel and is meant for this exact purpose with the benefit of being ordered.