Land Plugin

The land plugin renders Earth's landmasses. It uses TopoJSON data published to planet.plugins.topojson.world by the TopoJSON plugin. It uses the feature at objects.land in the TopoJSON object.

API

planetaryjs.plugins.land([config])

Valid keys for config are:

  • fill: the fillStyle to use for the context; defaults to "white"
  • stroke: the strokeStyle to use for the context; defaults to no value, resulting in no stroke around the landmasses
  • lineWidth the lineWidth to set on the context; only effective if stroke is set. Defaults to no value, resulting in no change to the context's lineWidth
JavaScript
planetaryjs.plugins.land({
  fill: '#339966', stroke: '#000000'
});

See also: