Skip to content

Commit

Permalink
fix color scale syntax in example code
Browse files Browse the repository at this point in the history
In the first example code in README, the call for setting the color range has a subtle syntax error which causes all hexagons to be displayed in gray.
  • Loading branch information
oliver committed Jun 2, 2015
1 parent fcbb026 commit b3f1986
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ var hexLayer = L.hexbinLayer(options).addTo(map);

// Optionally, access the d3 color scale directly
// Can also set scale via hexLayer.colorScale(d3.scale.linear()...)
hexLayer.colorScale().range('white', 'blue');
hexLayer.colorScale().range(['white', 'blue']);

// Set the data (can be set multiple times)
hexLayer.data([[lng1, lat1], [lng2, lat2], ... [lngN, latN]]);
Expand Down

0 comments on commit b3f1986

Please sign in to comment.