Skip to content

[pull] master from facebook:master#240

Merged
pull[bot] merged 1 commit intoMu-L:masterfrom
facebook:master
Sep 30, 2020
Merged

[pull] master from facebook:master#240
pull[bot] merged 1 commit intoMu-L:masterfrom
facebook:master

Conversation

@pull
Copy link
Copy Markdown

@pull pull bot commented Sep 30, 2020

See Commits and Changes for more details.


Created by pull[bot]. Want to support this open source service? Please star it : )

Summary:
Changelog: [internal]

Components can update state multiple times before the state update queue is flushed. This causes unnecessary layout/diff and mount passes. To solve this, drop stale state updates inside `stateUpdateQueue_ ` for specific `ShadowNodeFamily`.

Delivering stale status updates is redundant. Let's take SafeAreaView as an example. It schedules 5-6 state updates before `stateUpdateQueue_` is flushed. That's unnecessary work blocking JS thread. We only care about the latest state update. Same for TextInput and other components using state updates.

Reviewed By: JoshuaGross

Differential Revision: D23987707

fbshipit-source-id: 2e3f92cc93af61d78ac564aa40aef165af64b8c1
@pull pull bot added the ⤵️ pull label Sep 30, 2020
@pull pull bot merged commit 0544568 into Mu-L:master Sep 30, 2020
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.

1 participant