UUIDv7 generator with millisecond precision
npm install @kripod/uuidv7UUIDv7 generator based on the RFC4122 update proposal (draft-04)




``js
import { uuidv7 } from "@kripod/uuidv7";
let id = uuidv7();
console.log(id); // Example: 00ccebbc-13e0-7000-8b18-6150ad2d0c05
`
- K-sortable with 1ms precision _(Safari disallows sub-ms timing to defend against Spectre)_
- Time-ordered when sorted lexicographically
- Collision-resistant with distributed systems in mind
- Works until the year 10889, after which timestamps would overflow
| Chrome | Safari | Firefox | IE | Node.js | Deno |
| :----: | :----: | :-----: | :-----------------: | :-----: | :--: |
| ≥57 | ≥10 | ≥48 | No _(polyfillable)_ | ≥8 | ≥1 |
- Included in popular frameworks:
- Next.js
- Nuxt
- Gatsby