forked from extern/bruno
15 lines
394 B
JavaScript
15 lines
394 B
JavaScript
const { customAlphabet } = require('nanoid');
|
|
|
|
// a customized version of nanoid without using _ and -
|
|
const uuid = () => {
|
|
// https://github.com/ai/nanoid/blob/main/url-alphabet/index.js
|
|
const urlAlphabet = 'useandom26T198340PX75pxJACKVERYMINDBUSHWOLFGQZbfghjklqvwyzrict';
|
|
const customNanoId = customAlphabet (urlAlphabet, 21);
|
|
|
|
return customNanoId();
|
|
};
|
|
|
|
module.exports = {
|
|
uuid
|
|
};
|