Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add more methods for useStackState #790

Merged
merged 2 commits into from
Jan 20, 2022
Merged

feat: add more methods for useStackState #790

merged 2 commits into from
Jan 20, 2022

Conversation

mrdulin
Copy link
Contributor

@mrdulin mrdulin commented Jan 19, 2022

Changes to useStackState hook:

  1. Added clear and isEmpty methods.
  2. Added unit testings for the above methods.
  3. Use list.length instead of length in the closure to solve this eslint warning.
  4. Use generics instead of any type. Related issue useStackState and useQueueState are using any. we should instead use generics here. #586

@imbhargav5
Copy link
Owner

Incredible work! Love it @mrdulin !

@codecov
Copy link

codecov bot commented Jan 20, 2022

Codecov Report

Merging #790 (6db2a85) into main (42fae06) will increase coverage by 0.60%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #790      +/-   ##
==========================================
+ Coverage   76.20%   76.80%   +0.60%     
==========================================
  Files          67       67              
  Lines        1370     1371       +1     
  Branches      294      294              
==========================================
+ Hits         1044     1053       +9     
+ Misses        297      291       -6     
+ Partials       29       27       -2     
Impacted Files Coverage Δ
src/hooks/useQueueState.ts 100.00% <100.00%> (+36.36%) ⬆️
src/hooks/useStackState.ts 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 42fae06...6db2a85. Read the comment docs.

@imbhargav5 imbhargav5 merged commit fbf890f into imbhargav5:main Jan 20, 2022
@github-actions
Copy link
Contributor

🎉 This PR is included in version 5.9.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants