Pure PHP ulid implementation with binary encoding support.
Via Composer
$ composer require phpinnacle/ulid
<?php
use PHPinnacle\Ulid\Generator;
echo Generator::now();
echo Generator::fromDateTime(new \DateTimeImmutable('2019-01-22 23:33:45'));
echo Generator::fromTimestamp(1566310070);
$ composer test
We run benchmarks as follow:
$ composer bench
Please see CHANGELOG for more information on what has changed recently.
Please see CONTRIBUTING and CONDUCT for details.
If you discover any security related issues, please email dev@phpinnacle.com instead of using the issue tracker.
The MIT License (MIT). Please see License File for more information.