-
Notifications
You must be signed in to change notification settings - Fork 340
Description
Description
We (MetaMask) are using FlashList V2 to render our list of accounts. The user can open this list of accounts, tap one of them and this will change their globally selected account. However we noticed in testing that sometimes touch events are not being registered at all. This leaves the user tapping frantically with no feedback. This could be that the touch events are not firing, or it could be that the onPress is not registered for that cell. Either way the issue is weird and causing a UX regression in our app. The other curious aspect of this bug is that the issue does not occur every time you open the list but instead seems to happen randomly if the user touches the list quickly enough. This issue seems to only be effecting Android. If the user scrolls on the list, all cells become touchable and the list works as expected. Something about the initial load/lack of scrolling is causing this weird behaviour.
related issue: MetaMask/metamask-mobile#20735
Current behavior
- User opens account list
- User quickly taps an account to change their selected account preference
- Tap event does not register and leaves the list open with no action/feedback.
497099324-3811dbe8-83c7-4e7c-91fe-3f563bcaf62a.1.mp4
Expected behavior
- When the user touches the account cell, it should update the state to show that this is the new current selected account and close the list.
Reproduction
- Our code is open source and can be viewed/run here.
- Once you have setup the codebase, you can run the app locally via
- yarn setup
- yarn start:android
- Once the app builds, disable dev mode via developer settings (shake device, open dev options and toggle off dev mode)
- If this is too challenging I can try and find an easier way to share the code.3. create or import a wallet via the onboarding flow
- once onboarding is complete, you should be taken to the main home page
- click on the little drop down menu shown in the top left corner (for a new account it should say "Account 1")
- the list should open in a bottom sheet
- without scrolling on the list, quickly tab another account.
- See that the touch event is not triggering the on press handler for that cell
- Reproducing this issue is challenging since it does not occur every time. The user must quickly tap on the cell in the accounts list for this error to occur.
- Once the user scrolls on the screen, all cells become touchable. Therefore you must tap the screen before you do any scrolling in the list.
- I was not able to reproduce this issue in dev mode so you need to turn that of (via developer menu)
- This issue only seems to occur on Android phones. We tested with the latest pixel 8 so the performance of the phone is likely not the issue.
Platform
- iOS
- Android
- Web (if applicable)
Environment
React Native info output:
System:
OS: macOS 26.0.1
CPU: (14) arm64 Apple M4 Pro
Memory: 1.86 GB / 48.00 GB
Shell:
version: "5.9"
path: /bin/zsh
Binaries:
Node:
version: 20.18.0
path: ~/.nvm/versions/node/v20.18.0/bin/node
Yarn:
version: 3.8.7
path: ~/.nvm/versions/node/v20.18.0/bin/yarn
npm:
version: 10.8.2
path: ~/.nvm/versions/node/v20.18.0/bin/npm
Watchman:
version: 2025.07.21.00
path: /opt/homebrew/bin/watchman
Managers:
CocoaPods:
version: 1.16.2
path: /Users/owencraston/.rbenv/shims/pod
SDKs:
iOS SDK:
Platforms:
- DriverKit 25.0
- iOS 26.0
- macOS 26.0
- tvOS 26.0
- visionOS 26.0
- watchOS 26.0
Android SDK: Not Found
IDEs:
Android Studio: 2024.3 AI-243.25659.59.2432.13423653
Xcode:
version: 26.0.1/17A400
path: /usr/bin/xcodebuild
Languages:
Java:
version: 17.0.16
path: /usr/bin/javac
Ruby:
version: 3.1.6
path: /Users/owencraston/.rbenv/shims/ruby
npmPackages:
"@react-native-community/cli":
installed: 15.0.1
wanted: 15.0.1
react:
installed: 18.3.1
wanted: 18.3.1
react-native:
installed: 0.76.9
wanted: 0.76.9
react-native-macos: Not Found
npmGlobalPackages:
"*react-native*": Not Found
Android:
hermesEnabled: true
newArchEnabled: true
iOS:
hermesEnabled: true
newArchEnabled: true
FlashList version: 2.0.3
Additional context
What we have tried to fix the issue?
- Updating to v 2.1.0 did not fix the issue (our current version is 2.0.3
- I did some research that led me to believe this issue is a result of having the FlashList rendered inside a BottomSheet component using the
GestureHandler
(described in GestureHandler issue).- I tried moving our FlashList component outside of the BottomSheet and into a proper page and removing the
renderScrollComponent={ScrollView as React.ComponentType<ScrollViewProps>}
but this did not solve the issue.
- I tried moving our FlashList component outside of the BottomSheet and into a proper page and removing the
Key Files
- Our FlashList implementation lives here inside the MultichainAccountSelectorList
- This component is rendered inside the AccountSelector parent component.
- The parent renders this list inside a bottom sheet which is implemented here.
Checklist
- I've searched existing issues and couldn't find a duplicate
- I've provided a minimal reproduction (Expo Snack preferred)
- I'm using the latest version of @shopify/flash-list
- I've included all required information above