1.0.2 • Published 3 years ago
@cuvva/ksuid v1.0.2
ksuid
Generate prefixed, k-sorted globally unique identifiers. You can read more about them in our blog post.
Installation
$ yarn add @cuvva/ksuid
Usage
const ksuid = require('@cuvva/ksuid');
const id = ksuid.generate('user').toString();
// user_000000BgNwexbyo1VZs78wVMGdBo3
try {
const parsed = ksuid.parse('user_000000BgNwexbyo1VZs78wVMGdBo3');
} catch (error) {
console.log('uh oh!');
}
Testing
Install the development dependencies first:
$ yarn
Then run the tests 👩🔬:
$ yarn test
Support
Please open an issue on this repository.
License
MIT licensed - see LICENSE file
1.0.2
3 years ago
1.0.2-beta.2
3 years ago
1.0.2-beta.3
3 years ago
1.0.2-beta.1
3 years ago
1.0.2-beta.6
3 years ago
1.0.2-beta.7
3 years ago
1.0.2-beta.4
3 years ago
1.0.2-beta.5
3 years ago
1.0.1
3 years ago
1.0.0
5 years ago