Skip to content

Instantly share code, notes, and snippets.

@urre
Created November 12, 2012 16:51
Show Gist options
  • Save urre/4060461 to your computer and use it in GitHub Desktop.
Save urre/4060461 to your computer and use it in GitHub Desktop.
Random colors in SASS
# SASS Random colors ex. background-color: getRandomColor();
# Add to config.rb
module Sass::Script::Functions
def getRandomColor()
Sass::Script::String.new("#%06x" % (rand * 0xffffff))
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment