-
Notifications
You must be signed in to change notification settings - Fork 45.6k
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
Selectively hydrate during capture phase #22440
Selectively hydrate during capture phase #22440
Conversation
Comparing: f35287d...ae5f6a3 Critical size changesIncludes critical production bundles, as well as any change greater than 2%:
Significant size changesIncludes any change greater than 0.2%: (No significant changes) |
@@ -25,4 +25,4 @@ export const SHOULD_NOT_DEFER_CLICK_FOR_FB_SUPPORT_MODE = | |||
// will result in endless cycles like an infinite loop. | |||
// We also don't want to defer during event replaying. | |||
export const SHOULD_NOT_PROCESS_POLYFILL_EVENT_PLUGINS = | |||
IS_EVENT_HANDLE_NON_MANAGED_NODE | IS_NON_DELEGATED | IS_CAPTURE_PHASE; | |||
IS_EVENT_HANDLE_NON_MANAGED_NODE | IS_NON_DELEGATED; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm a little concerned based off this comment here:
// We don't process these events unless we are in the |
Not sure what the effect on those plugins would be or how to test they dont act up? @gaearon any suggestions?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm I see some failing tests I'll take a look at those first
I doubt this is safe in this way. It seemed more complicated last I looked at it. Since the next step is to remove the replaying, what's the point of this intermediate step? We might still need it for continuous but the code structure might look different at that point anyway so it might be easier to do then. |
Summary
This PR adds selective hydration in the capture phase of an event. This makes it so that we run react
on*Capture
listeners after hydrating.How did you test this change?
Jest