const uuid = (Math.random() + 1).toString(36).substring(2);
console.log(uuid);
const makeid = (length) => {
var result = '';
var characters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789';
var charactersLength = characters.length;
for ( var i = 0; i < length; i++ ) {
result += characters.charAt(Math.floor(Math.random() *
charactersLength));
}
return result;
}
let uid = Date.now().toString(36) + Math.random().toString(36).substr(2)
// result string would be like "l7hgwnf0qfztje7bn3"
function uid() {
let a = new Uint32Array(3);
window.crypto.getRandomValues(a);
return (performance.now().toString(36)+Array.from(a).map(A => A.toString(36)).join("")).replace(/./g,"");
};