Description
It includes Set, Map, hash table, priority queue and other data structures implemented using RB-tree, with extremely complete unit tests and performance tests and complete api documentation.
It supports CommonJS and ES modules, and supports the introduction of browser script tags. It is written in TypeScript and has strict type deduction.
js-sdsl alternatives and similar libraries
Based on the "Data Structure" category.
Alternatively, view js-sdsl alternatives based on common mentions on social networks and blogs.
-
immutable-js
Immutable persistent data collections for Javascript which increase efficiency and simplicity. -
mori
ClojureScript's persistent data structures and supporting API from the comfort of vanilla JavaScript -
object-path
A tiny JavaScript utility to access deep properties using a path (for Node and the Browser) -
hashmap
HashMap JavaScript class for Node.js and the browser. The keys can be anything and won't be stringified -
schemapack
Create a schema object to encode/decode your JSON in to a compact byte buffer with no overhead. -
omniclone
An isomorphic and configurable javascript utility for objects deep cloning that supports circular references. -
property-path
Get and set object properties using a string path, where you can specify the separator character in the path.
InfluxDB - Purpose built for real-time analytics at any scale.
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of js-sdsl or a related project?
Popular Comparisons
README
js-sdsl
A javascript standard data structure library which benchmark against C++ STL.
Included data structures
- Vector
- Stack
- Queue
- LinkList
- Deque
- PriorityQueue
- OrderedSet (using RBTree)
- OrderedMap (using RBTree)
- HashSet
- HashMap
Supported platforms
- node.js (using commonjs)
- react/vue (using es5)
- browser (support most browsers)
Download
Download directly
- js-sdsl.js (for development)
- js-sdsl.min.js (for production)
Or install js-sdsl using npm
npm install js-sdsl
Usage
To help you have a better use, we provide this API document.
For Browser
<!-- you can download the file locally and import it or import it dynamically by using url. -->
<script src="https://zly201.github.io/js-sdsl/js-sdsl.min.js"></script>
<script>
const { Vector } = sdsl;
const myVector = new Vector();
// you code here...
</script>
Build by source code
You can pull this repository and run yarn build
to rebuild this library.
Unit test
For check
We use jest library to write unit tests, you can see test coverage on coveralls. You can run yarn test:check
command to reproduce it.
For performance
We tested most of the functions for efficiency. You can go to testResult.txt
to see our running results or reproduce it with yarn test:performance
command.
Maintainers
Contributing
Feel free to dive in! Open an issue or submit PRs.
Contributors
Thanks goes to these wonderful people (emoji key):
<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section --> <!-- prettier-ignore-start --> <!-- markdownlint-disable --> Takatoshi Kondo💻 ⚠️
<!-- markdownlint-restore --> <!-- prettier-ignore-end --> <!-- ALL-CONTRIBUTORS-LIST:END -->
This project follows the all-contributors specification. Contributions of any kind welcome!
License
MIT © ZLY201
*Note that all licence references and agreements mentioned in the js-sdsl README section above
are relevant to that project's source code only.