antares/src/common/libs/uidGen.ts

4 lines
145 B
TypeScript
Raw Normal View History

2022-05-10 12:57:25 +02:00
export function uidGen (prefix?: string) {
2022-11-26 11:21:47 +01:00
return (prefix ? `${prefix}:` : '') + Math.random().toString(36).substring(2, 11).toUpperCase();
2022-05-10 12:57:25 +02:00
}