Just Random Color

Some time ago I was working on app where for each category we had to assign random color in case that user didn’t choose one. A few day ago I needed to generate random color again. Instead of copy/paste code from one place to another much better is to create re-usable module. Also, this might not be unusual request and potentially could be useful to others.

just-randomcolor2

just.RandomColor is Javascript random color generator in one of hex, RGB, RGBA formats and it can return object with color data or CSS string. It can be used on both, client and server side.


Usage is really simple and you can find more details in DOCUMENTATION.

For bugs of suggestions please write a issue on GITHUB.

If you’re interested to see just.RandomColor in action I’ve prepare small DEMO.

  • News Ticker in 4 lines of jQuery (93)
    There are a lot of different jQuery News Ticker plugins with lot of options that you can use. Do you want to learn how to create one on your own in only 4 lines of jQuery code […]
  • Image gallery in 4 lines of code with MooTools and Dojo (8)
    Recently I wrote article how to create image gallery with description in 4 lines of jQuery code. Now, I will do the same thing with two other popular JavaScript frameworks, MooTools and […]
  • jqBarGraph – jQuery graph plugin (157)
    jqBarGraph is jQuery plugin that gives you freedom to easily display your data as graphs. There are three types of graphs: simple, multi and stacked. All you have to do is to pass your […]
  • mooBarGraph: AJAX graph for MooTools (18)
    mooBarGraph is AJAX graph plugin for MooTools which support two types of graphs, simple bar and stacked bar graph. This plugin made graph from your JSON data and is compatible with all […]
  • JavaScript Art: Triangles (1)
    You can see abstract triangles art everywhere these days. They are on banners, wallpapers, decorative pillows, fliers, tattoos, book covers... Just put a bunch of triangles and some colors […]

no comments on "Just Random Color"

Leave a Reply

Your email address will not be published. Required fields are marked *