Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feature/use rerender props in wrapper #381

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

Merged

Conversation

Copy link
Contributor

@adamseckel adamseckel commented Jun 4, 2020
edited
Loading

What:

Updates renderHook to pass props into a provided wrapper component. See discussion here: #322 w @mpeyper

Why:

This allows easily testing how a hook response to changes in a parent context, without having to mutate values in test code.

How:

Pass the value of hookProps.current into render.

Checklist:

  • Documentation updated
  • Tests
  • Ready to be merged
  • Added myself to contributors table

josejulio and zeshantahir105 reacted with hooray emoji
Copy link

codecov bot commented Jun 4, 2020
edited
Loading

Codecov Report

Merging #381 into master will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@ Coverage Diff @@
## master #381 +/- ##
=========================================
 Coverage 100.00% 100.00% 
=========================================
 Files 4 4 
 Lines 94 94 
 Branches 15 15 
=========================================
 Hits 94 94 
Impacted Files Coverage Δ
src/pure.js 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 e77aab8...5eaac2d. Read the comment docs.

Copy link
Member

@mpeyper mpeyper left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perfect, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@mpeyper mpeyper mpeyper approved these changes

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /