v2.0.0
Breaking changes to API with new module format
We're modernizing the library, with proper ES6 export
ing, and CommonJS support with rollup
. As a result, the API will change.
For TypeScript and ES6 consumers
import { ulid, factory, monotonicFactory } from 'ulid'
ulid()
For CommonJS consumers
Sorry guys, if you can tell me a better way, I'd be happy to implement it!
const ULID = require('ulid')
ULID.ulid()
For browser usage
<script src="/path/to/ulid.js"></script>
<script>
ULID.ulid()
</script>