Random color from string in javascript Consider a list of strings you need to permanently assign a random color. First you should turn the string into a hash. var string = "string" var hash = 0