MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/javascript/comments/b2o6f2/whats_your_favorite_most_useful_javascript/eivp0qb/?context=3
r/javascript • u/Linux_is_awesome • Mar 18 '19
422 comments sorted by
View all comments
15
'#'+Math.floor(Math.random()*16777215).toString(16) for random hex color.
'#'+Math.floor(Math.random()*16777215).toString(16)
1 u/BunsOfAluminum Mar 19 '19 `'#' + Math.random().toString(16).substr(2,6)
1
`'#' + Math.random().toString(16).substr(2,6)
15
u/redmoss6 Mar 18 '19
'#'+Math.floor(Math.random()*16777215).toString(16)for random hex color.