Popularity
2.2
Growing
Activity
8.9
Declining
358
16
37

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.

Programming language: TypeScript
License: MIT License
Tags: Data Structure     Nodejs     TypeScript     JavaScript     Map     Set    
Latest version: v4.0.0-beta.0

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.

Do you think we are missing an alternative of js-sdsl or a related project?

Add another 'Data Structure' Library

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

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

@ZLY201.

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.