sqids / sqids-go

Official Go port of Sqids. Generate short unique IDs from numbers.
https://sqids.org/go
MIT License
536 stars 11 forks source link

Does it support numeric-only IDs #2

Closed linchupeng closed 1 year ago

linchupeng commented 1 year ago

Is it possible to support numeric-only IDs

4kimov commented 1 year ago

Try this:

alphabet := "0123456789"
s, _ := sqids.NewCustom(sqids.Options{
    Alphabet: &alphabet,
})