Comments (3)
You can't use that library to generate a unique ID. You might prefer https://github.com/rs/xid for this use case.
hashids are for encoding a number/numbers into a user facing string (e.g a URL).
from go-hashids.
hi @speps
yes i know , i already have unique integer id using this id i generate hashed string .
my q is what is min length ?
from go-hashids.
That's how long you want the resulting string to be. It will use more anyway if needed to encore more numbers or bigger numbers. You can leave at the default value and you should be okay.
from go-hashids.
Related Issues (20)
- hashing uuids? HOT 2
- DecodingWithError does not produce error HOT 5
- NewWithData should not panic but return error
- Alphabet allows spaces
- Ignoring NewWithData error leads to runtime errors HOT 1
- Fix for #28 just broke MinLength HOT 4
- Push a new tag please HOT 1
- Not compatible with JS/PHP version HOT 8
- Please add a release tag (for better compatibility with go dep) HOT 2
- Epoch hashing HOT 1
- Please support big int HOT 3
- import error
- Is it possible to check one string is a hashid? HOT 2
- allow numbers only alphabet HOT 2
- Create v2.0.1, a valid go module version HOT 14
- Please tell if the implementation is thread safe HOT 1
- The calculation result of hexadecimal string is different from python or javascript
- Look like this project is no longer being maintained HOT 3
- Can it encode string?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from go-hashids.