Repository navigation
Fix stale state in RNTester's Touchable and Pressable event log examples - #60433
Merged
Merged
Conversation
The event log examples built each entry from stale state, so events handled in the same React batch overwrote each other. This made the `touchable/feedback-events/pressed` screenshot flaky. They now use a functional state updater, as `PressableFeedbackEvents` already does. The screenshot changes from `press`, `pressIn` to `press`, `pressOut`, `pressIn` on iOS and Android. Changelog: [Internal]
cortinico
approved these changes
Dec 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The event log examples built each entry from stale state, so events handled in the same React batch overwrote each other. This made the
touchable/feedback-events/pressedscreenshot flaky, and it falsely failed #60396. They now use a functional state updater, asPressableFeedbackEventsalready does.The screenshot changes from
press/pressIntopress/pressOut/pressInon iOS and Android, so this needsvisual-change-approved.Changelog: [Internal]
Test plan:
Ran
touchable.yml3/3 on an iPhone 17 Pro simulator, against themainRelease app with this branch's JS bundle swapped in. Every capture showed all three events.