10 lines
303 B
TypeScript
10 lines
303 B
TypeScript
export default class Strings {
|
|
public static randomString(length: number): string {
|
|
return (Date.now().toString(36) + Math.random().toString(36).substring(2)).substring(0, length);
|
|
}
|
|
|
|
private constructor() {
|
|
throw new Error('Strings is a static class that may not be instantiated');
|
|
}
|
|
}
|