Merge pull request #8851 from fredj/rbush_types

Use typescript types for RBush
This commit is contained in:
Frédéric Junod
2018-10-24 17:21:17 +02:00
committed by GitHub
2 changed files with 2 additions and 2 deletions

View File

@@ -42,6 +42,7 @@
"@openlayers/eslint-plugin": "^4.0.0-beta.1", "@openlayers/eslint-plugin": "^4.0.0-beta.1",
"@types/arcgis-rest-api": "^10.4.3", "@types/arcgis-rest-api": "^10.4.3",
"@types/geojson": "^7946.0.4", "@types/geojson": "^7946.0.4",
"@types/rbush": "^2.0.2",
"@types/topojson-specification": "^1.0.0", "@types/topojson-specification": "^1.0.0",
"buble": "^0.19.3", "buble": "^0.19.3",
"buble-loader": "^0.5.1", "buble-loader": "^0.5.1",

View File

@@ -221,8 +221,7 @@ class RBush {
* @return {import("../extent.js").Extent} Extent. * @return {import("../extent.js").Extent} Extent.
*/ */
getExtent(opt_extent) { getExtent(opt_extent) {
// FIXME add getExtent() to rbush const data = this.rbush_.toJSON();
const data = this.rbush_.data;
return createOrUpdate(data.minX, data.minY, data.maxX, data.maxY, opt_extent); return createOrUpdate(data.minX, data.minY, data.maxX, data.maxY, opt_extent);
} }