Skip to content

Revert shadow-tree commit-lifecycle hooks - #44

Open
piaskowyk wants to merge 1 commit into
0.86.0-discordfrom
piaskowyk/revert-shadow-tree-commit-hooks
Open

Revert shadow-tree commit-lifecycle hooks#44
piaskowyk wants to merge 1 commit into
0.86.0-discordfrom
piaskowyk/revert-shadow-tree-commit-hooks

Conversation

@piaskowyk

@piaskowyk piaskowyk commented Sep 8, 2026

Copy link
Copy Markdown

Summary:

Reverts 9eee718 ([Android] shadow-tree commit-lifecycle hooks, ported from react-native-archived#100), which added shadowTreeCommitSucceeded / shadowTreeCommitFinalized to ShadowTreeDelegate and UIManagerCommitHook, fired them from ShadowTree::tryCommit (via a Discord-only ScopeGuard/defer helper) and fanned them out from UIManager.

New measurements show that this change does not affect performance. This PR is part of the props-registry equality eviction of Reanimated updates, which is already solved in a different way inside Reanimated, as well as in Reanimated 4.

@SzymczakJ SzymczakJ left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM, race conditions that were bugging us here are already fixed in reanimated, so we can get rid of it.

This reverts commit 9eee718.

The shadowTreeCommitSucceeded / shadowTreeCommitFinalized hooks existed
only to make Reanimated's props-registry equality eviction race-free.
That eviction turned out to be performance neutral and has been removed
from the Reanimated fork, so nothing overrides these hooks anymore and
the fork can drop the divergence from upstream in ShadowTree,
ShadowTreeDelegate, UIManager and UIManagerCommitHook.

Also restores the configureEventEmitterCallback() call in
SampleTurboModuleSpec.cpp, which that commit had incidentally commented
out.

Co-authored-by: Cursor <cursoragent@cursor.com>
@piaskowyk
piaskowyk force-pushed the piaskowyk/revert-shadow-tree-commit-hooks branch from 2a3c841 to 6567776 Compare September 10, 2026 12:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants