13 lines
293 B
TypeScript
Raw Normal View History

2024-11-05 10:09:18 +08:00
/**
* 010000
*/
export const generateId = (): number => Math.floor(Math.random() * 10000)
/**
* 0 max
* @param max
* @returns
*/
export const getRandomInt = (max: number) =>
Math.floor(Math.random() * Math.floor(max))