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

Fix forceUpdate in shallow test renderer #11239

Merged
merged 1 commit into from
Oct 18, 2017
Merged

Conversation

d4rky-pl
Copy link
Contributor

Fixes #11236 by adding a flag during enqueueForceUpdate to make sure the shouldComponentUpdate is not being tested against.

@@ -188,6 +190,7 @@ class Updater {
}

enqueueForceUpdate(publicInstance, callback, callerName) {
this._renderer._forcedUpdate = true;
Copy link
Collaborator

@gaearon gaearon Oct 17, 2017

Choose a reason for hiding this comment

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

Since you're adding a new field can you also initialize it in the constructor please?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done!

@gaearon gaearon merged commit 03a3934 into facebook:master Oct 18, 2017
@gaearon
Copy link
Collaborator

gaearon commented Oct 18, 2017

I think this looks good. Thanks.

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

Successfully merging this pull request may close these issues.

3 participants