shrink-mongo-id
v2.1.4
Published
Heavily based on https://github.com/treygriffith/short-mongo-id
Downloads
23
Readme
Shorten MongoDb ObjectId
Heavily based on https://github.com/treygriffith/short-mongo-id
But without external node dependencies.
Suit for node
and browser
.
Install
npm install --save shrink-mongo-id
Usage
const shortid = require('shrink-mongo-id');
const shortnd = shortid('5d0efa88f85b2f001172f6ba');
console.log(shortnd); // => 'ahGw2K'