RBushWeb
Find the nearby.
Skip the rest.
Make spatial queries tangible with an R-tree for points and rectangles, nearest neighbors and inspectable bounds.
R-tree spatial indexing
Index immutable envelopes, query the relevant area, and keep rendering separate. The same headless engine works in the browser and workers.
Intersection & nearest neighbors
Create an RBush, then Insert or BulkLoad objects with an Envelope. Search with a rectangle or use Knn for nearest neighbors.
Bulk load & inspectable nodes
Delete an item using its old bounds before moving it, then insert it with the new envelope. Clear an index when its dataset is discarded.
NOT A SCREENSHOT
Get a feel for it.
Preparing RBushWeb
The playground loads when it comes into view.
A SMALL FIRST STEP
Give geometry an index.
Index immutable envelopes, query the relevant area, and keep rendering separate. The same headless engine works in the browser and workers.
Read the usage guidenpm install @wieslawsoltes/rbushweb@0.1.1Pinned to the published package used in this showcase. No unpublished features implied.