Skip to content

Instantly share code, notes, and snippets.

@shiv19
Last active August 9, 2019 23:03
Show Gist options
  • Save shiv19/61e486490dfa63b68c8d9e79ff04d477 to your computer and use it in GitHub Desktop.
Save shiv19/61e486490dfa63b68c8d9e79ff04d477 to your computer and use it in GitHub Desktop.
get random hex color codes
const randColor = () => '#' + ('00000'+(Math.random()*(1<<24)|0).toString(16)).slice(-6);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment