2.0.1 • Published 7 years ago
lite-id v2.0.1
lite-id
A simple nodejs module for generate unique string id.
Installation
npm install lite-id
When should I use lite-id?
You need to generate a simple unique id in code.
API
var id = require('lite-id');
console.log(id());
//Result: J6YgVpwp1929
id(length)
Generates an id. Optional length is set resulting id length. Default length is 10.
Tests
Lite-id have a mocha test to find collisions on generated id's. Test for 3,000,000 unique id's with default length and consist is passed and processed without conflicts.
npm test //standart test with 60K instances
npm run extended_test //extended test with 3M instances
Examples
With default length
var id = require('lite-id');
console.log(id());
//Result: J6YgVpwp1929
With custom length
var id = require('lite-id');
console.log(id(20));
//Result: jXf315M_G10SQKa2786RG
2.0.1
7 years ago
2.0.0
7 years ago
1.3.3
9 years ago
1.3.2
9 years ago
1.3.0
9 years ago
1.2.7
9 years ago
1.2.6
9 years ago
1.2.5
9 years ago
1.2.4
9 years ago
1.1.4
9 years ago
1.1.3
9 years ago
1.1.2
9 years ago
1.0.2
9 years ago
1.0.1
9 years ago
1.0.0
9 years ago
0.0.6
9 years ago
0.0.5
9 years ago
0.0.4
9 years ago
0.0.3
9 years ago
0.0.2
9 years ago
0.0.1
9 years ago
0.0.0
9 years ago