Skip to content

Instantly share code, notes, and snippets.

@flockonus
Last active March 27, 2018 18:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save flockonus/ca3cbb9c5f19e3746cba827e6badc8c9 to your computer and use it in GitHub Desktop.
Save flockonus/ca3cbb9c5f19e3746cba827e6badc8c9 to your computer and use it in GitHub Desktop.
Random 8-length string JS
// Really fast way to create 8 bytes random string =~ 1e12 possibilities
Math.round(Math.random() * 1e13).toString(32).substr(-8,8)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment