js生成随机不重复ID

来源:互联网 发布:js split 数组 length 编辑:程序博客网 时间:2024/05/19 21:44
function createRandomId() {
            return (Math.random()*10000000).toString(16).substr(0,4)+'-'+(new Date()).getTime()+'-'+Math.random().toString().substr(2,5);
        }
原创粉丝点击