Skip to content

Commit 63fc4c6

Browse files
authored
docs: documentation updates
1 parent d9848e9 commit 63fc4c6

File tree

1 file changed

+19
-3
lines changed

1 file changed

+19
-3
lines changed

README.md

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,30 @@ const { s2 } = require('s2js')
3434
</script>
3535
```
3636

37-
### Typescript Support
38-
39-
The library is written in Typescript and exports type definitions.
37+
### Features
38+
39+
s2js is a full-featured JavaScript/TypeScript port of Google's S2 Geometry library. It supports:
40+
41+
| Feature | Supported? | Notes |
42+
|----------------------------------|:---------:|:------|
43+
| **CellId, Cell** || Encoding, decoding, neighbors |
44+
| **Point, LatLng** || Spherical & Planar projections |
45+
| **Loop, Polygon** || Polygons, potentially with holes |
46+
| **Polyline** || Represents linear paths |
47+
| **RegionCoverer** || Cover regions (loops, polys) with S2 cells |
48+
| **GeoJSON <> S2 conversions** || Supports all GeoJSON geometry types |
49+
| **Polygon contains/intersects** || Point-in-polygon & shape intersection |
50+
| **Union, Intersection, Difference** || Basic boolean polygon operations |
51+
| **BigInt cell/token conversion** || Handles full 64-bit cell IDs |
4052

4153
### Feature Completeness
4254

4355
The library is essentially feature compatible with the Golang library: https://github.com/golang/geo
4456

57+
### Typescript Support
58+
59+
The library is written in Typescript and exports type definitions.
60+
4561
### GeoJSON support
4662

4763
The supplementary `geojson` module provides convenience functions for working with GeoJSON data in S2:

0 commit comments

Comments
 (0)