1 Star 0 Fork 501

sjm / NocoBase

forked from NocoBase / NocoBase 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
uid.js 205 Bytes
一键复制 编辑 原始数据 按行查看 历史
chenos 提交于 2021-07-11 22:20 . lots of updates
let IDX = 36,
HEX = ''
while (IDX--) HEX += IDX.toString(36)
function uid(len = 11) {
let str = '',
num = len || 11
while (num--) str += HEX[(Math.random() * 36) | 0]
return str
}
console.log(uid());
TypeScript
1
https://gitee.com/sjm/nocobase.git
git@gitee.com:sjm/nocobase.git
sjm
nocobase
NocoBase
develop

搜索帮助