SortAO is a fast, zero-dependency sorted container suite for JavaScript & TypeScript!
We provides 4 advanced wrappers out of the box:
SortedMap,SortedSet,SortedMultimap,SortedMultiset
These wrappers can replace the underlying data structure to adapt to different performance patterns.
- Flat:
SortedBlockArray(default),SortedBlockList,SortedBlockDeque - Tree:
SplayTree
npm i sortaoFull documentation is available at sortao.com.
import { SortedSet } from "sortao";We have provided approximately 500 test cases, including large-scale stress tests.
You may clone the repository and manually run pnpm test or pnpm coverage.
Partial benchmarks and analyses can be found in the document.
You may clone the repository and manually run pnpm bench.
MIT