Created
January 11, 2021 09:32
-
-
Save rawnly/419a156dcc8c250d3c231f7dc2df8819 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const generateRandomString = (length: number): string => | |
`1${"0".repeat(length)}`.replace(/[01]/g, () => (0 | (Math.random() * 16)).toString(16)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment