js v2.0.0: rename protocol.tileFunc -> tile, CHANGELOG, README

This commit is contained in:
Brandon Liu
2022-10-13 09:59:56 +08:00
parent bdc01d5a4e
commit cf20dcd0ce
4 changed files with 26 additions and 5 deletions

View File

@@ -1,3 +1,24 @@
2.0.0
* Major version bump, changing the JS API.
* Support for PMTiles spec version 3 archives.
* Backwards compatibility with v2 archives.
* Leaflet and MapLibre adapters support tile cancellation, improving performance significantly.
* ETag and Retry support for archives that are updated in-place.
* Cache-Control and Expires header support for MapLibre.
Clearer API names:
```js
const p = new pmtiles.PMTiles('example.pmtiles')
pmtiles.leafletRasterLayer(p).addTo(map)
```
```js
let protocol = new pmtiles.Protocol();
maplibregl.addProtocol("pmtiles",protocol.tile);
```
1.0.0
* Breaking change, introducing new TypeScript module with more clearly defined interfaces.