Skip to main content
使用 crypto.randomUUID() 生成 UUID v4。它在 Bun、Node.js 和浏览器中均可使用,无需依赖。

Bun 还提供 Bun.randomUUIDv7(),用于生成 UUID v7

参见 工具