File tree Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Original file line number Diff line number Diff line change 1
1
import type * as geojson from 'geojson'
2
2
import { MAX_LEVEL } from '../s2/cellid_constants'
3
3
import { CellUnion } from '../s2/CellUnion'
4
- import * as geometry from './geometry'
4
+ import { fromGeoJSON } from './geometry'
5
5
import { Polyline } from '../s2/Polyline'
6
6
import { Polygon } from '../s2/Polygon'
7
7
import type { Region } from '../s2/Region'
@@ -99,8 +99,8 @@ export class RegionCoverer {
99
99
}
100
100
101
101
/** Returns a CellUnion that covers the given GeoJSON geometry and satisfies the various restrictions. */
102
- covering ( geom : geojson . Geometry ) : CellUnion {
103
- const shape = geometry . fromGeoJSON ( geom )
102
+ covering ( geometry : geojson . Geometry ) : CellUnion {
103
+ const shape = fromGeoJSON ( geometry )
104
104
if ( Array . isArray ( shape ) ) return this . mutliMemberCovering ( shape as Region [ ] )
105
105
return this . coverer . covering ( shape )
106
106
}
Original file line number Diff line number Diff line change 2
2
* Module geojson implements types and functions for working with GeoJSON.
3
3
* @module geojson
4
4
*/
5
- export type { Encodable , Decodable } from './geometry'
5
+ export * as geojson from 'geojson'
6
+
7
+ export { Encodable , Decodable } from './geometry'
6
8
export { toGeoJSON , fromGeoJSON } from './geometry'
7
9
8
- export type { RegionCovererOptions } from './RegionCoverer'
10
+ export { RegionCovererOptions } from './RegionCoverer'
9
11
export { RegionCoverer } from './RegionCoverer'
You can’t perform that action at this time.
0 commit comments