This is a fork of Tomer Doron's gauge.js implementation of "google style gauge's using d3.js". It adds lots more configuration options, including the ability to rotate the gauge and change the size of the gap, and will (shortly) allow dynamic updating of the coloured bands (useful for, e.g., TCAS simulations) and variable-size ranges.
If you just want to use the module to create gauges, you can grab the file d3-gauge-plus.js
from the dist
folder in this repository (or if you prefer, the minified version) and include it in your projects. See the demos page (and accompanying source in the repository) for more information.
If you want to modify the library, you'll need to rebuild it from its constituent parts. We use grunt to compile the sources (which are in lib) to the target d3-gauge-plus.js
library using browserify, and then minify that to d3-gauge-plus.min.js
using uglify.
To get started, you need to do two things:
First, ensure you've got grunt installed. Hopefully that's as simple as:
npm install -g grunt-cli
More detailed instructions are here.
Second, in the root folder of this repository, install dependencies via:
npm install
Then you should be able to run grunt
to lint/browserify/minify the sources all together. It's all controleld by Gruntfile.js.