shortuuid
go-nanoid
shortuuid | go-nanoid | |
---|---|---|
1 | 4 | |
1,147 | 420 | |
- | - | |
5.4 | 3.7 | |
7 days ago | 29 days ago | |
Go | Go | |
MIT License | GNU General Public License v3.0 only |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
shortuuid
-
CVE-2021-3538 issued for latest release of github.com/satori/go.uuid
use https://github.com/google/uuid instead. It is maintained and have some nice add-on dependency like https://github.com/lithammer/shortuuid
go-nanoid
-
snips.sh: passwordless, anonymous SSH-powered pastebin
Using jaevor/go-nanoid for those short IDs. With a ID length of 10 it'll take about ~17 years to have ~1% chance of collision.
- Which UUID package do you use? and why?
-
rs-nanoid: efficient NanoID generation in Rust
With criterion benchmarking, nanoids of length 255 average about 101ns to generate, whereas in my Go implementation they take over 470ns. I know this is just benchmarking and only nanoseconds, but it's nice to have a comparison.
- Very efficient Nano ID gen in Go
What are some alternatives?
uuid - Go package for UUIDs based on RFC 4122 and DCE 1.1: Authentication and Security Services.
uuid - A UUID package originally forked from github.com/satori/go.uuid
nanoid - A tiny and fast Go unique string generator
go.uuid - UUID package for Go
ksuid - K-Sortable Globally Unique IDs
snips.sh - ✂️ passwordless, anonymous SSH-powered pastebin with a human-friendly TUI and web UI
Monoton - Highly scalable, single/multi node, sortable, predictable and incremental unique id generator with zero allocation magic on the sequential generation
nanoid - A tiny (124 bytes), secure, URL-friendly, unique string ID generator for JavaScript
sonyflake - A distributed unique ID generator inspired by Twitter's Snowflake
bubbletea - A powerful little TUI framework 🏗