Skip to content

1.0.0

Latest
Compare
Choose a tag to compare
@rob-murray rob-murray released this 19 Mar 09:21
· 3 commits to master since this release
9a7d11e

Stable release!

This change updates the library to use Leaflet > 1.0 and introduces some API changes. We now follow semantic versioning - no more breaking changes.

  • Leaflet JS version 1.x

  • Proj4Leaflet dependency update

  • API change (see below)

  • Use OS OpenSpace https tile server URL

  • OS OpenSpace Logo in map (attribution: false to remove)

  • Link to OS OpenSpace Terms of Use (attribution: false to remove)

API Changes

// Get CRS
L.OSOpenSpace.getCRS(); => L.OSOpenSpace.CRS;

var map = new L.Map('map', {
  zoom: 6,
  crs: L.OSOpenSpace.CRS,
});


// Get tileLayer
var openspaceLayer = L.tileLayer.OSOpenSpace("<API Key>", options);
map.addLayer(openspaceLayer);

=>
var openspaceLayer = L.OSOpenSpace.tilelayer("<API Key>", "<API URL>", options);
map.addLayer(openspaceLayer);