This is the documentation of version 1.0.0-rc.4. Go to the latest version, 1.0.0-rc.5.
TomTom Maps for JavaScript
    Preparing search index...

    Function bboxFromCoordsArray

    • The bounding box of an array of [longitude, latitude] positions, or undefined if empty.

      • It reads the positions as loose points, with no edges between them. For a line or a ring, pass it as GeoJSON to bboxFromGeoJSON, which follows its edges.
      • It crosses the antimeridian, with west > east, when that box is narrower than the one from the lowest to the highest longitude. A tie, or positions spanning -180 to 180, keeps the latter.
      • A very long array is sampled rather than scanned in full, which keeps the box close to exact.

      Parameters

      Returns OptionalBBox