@sugardarius/react-use-algos v1.8.0
Greetings 👋
React Use Algos
is an npm package which proposes you a libray of React Hooks to use some collections, formulas and algos 💪🏻
This project is made to be open source and driven by the community so please feel free to send your feed back, ideas and of course your PRs are welcome 🙏🏻
First things first 😜
Let's begin by installing the package:
npm install --save @sugardarius/react-use-algos
Which hooks are availables?
In this project you can find theses, I hope, useful hooks! If you need a Storybook is available here 😊
Collections
Collections hooks are implementations of data structures:
- useBinaryHeap: implementation of the Binary Heap (max or min)
- useMap: a tracking of a map (here as literal object)
- useQueue: an implementation Queue data structure in FIFO method
- useSet: a racking of a Set
- useStack: an implementation of the Stack data structure in LIFO method
Algos
Algos hooks are implementation of algorithms:
- misc:
- useMinReachJumps: an implementation of a misc algo:
min jump
. - useTankCapacity: an implementation of a misc algo:
tank capacity
- useMinReachJumps: an implementation of a misc algo:
- random:
- useShuffle: an implementation of the
shuffle
algo.
- useShuffle: an implementation of the
- search:
- useBinarySearch: an implementation of the
binary search
algo - useLinearSearch: an implementation of the
linear search
algo
- useBinarySearch: an implementation of the
- sorting:
- useBubbleSort: an implementation of the
bubble sort
algo - useQuickSort: an implementation of the
quick sort
algo - useSelectionSort: an implementation of the
selection sort
algo
- useBubbleSort: an implementation of the
Formulas
Formulas hooks are implementations of some well known formulas:
- useLerp: an implementation of the precise linear interpolation formula
Want to help? 😍
If you want to make any controbutions to this projet to fix a bug, add a new hook or improve the documentation your are welcome 🙏🏻 You can read up our contributing guidelines.
Special thanks 👏
Many thanks to the react-use project from streamich which has inspired this project. We can do more with React Hooks! 💪🏻