Closed
Description
In the future we want geoChoroplethChart to default to the null (identity) projection since it is built on d3.geoPath
which so defaults.
However we have the opportunity to get there in a backward-compatible way, with a deprecation warning.
Here's one way to get there:
- add a member
_projection
, which defaults to undefined - at the start of
doRender
anddoRedraw
(maybe in a helper function)
if(_projection === undefined) {
console.warn('choropleth projection default of geoAlbers is deprecated');
_geoPath.projection(d3.geoAlbers());
} else {
_geoPath.projection(_projection);
}
geoChoroplethChart.projection
becomes a regular getter/setter of_projection
(note getter is currently broken)
Metadata
Metadata
Assignees
Labels
No labels