react-native-pager-view
react-native-pager-view copied to clipboard
[Android] VirtualizedList: Encountered an error while measuring a list's offset from its containing VirtualizedList
Environment
System: OS: Windows 10 10.0.19042 CPU: (12) x64 AMD Ryzen 5 3600 6-Core Processor Memory: 6.69 GB / 15.95 GB Binaries: Node: 16.13.0 - C:\Program Files\nodejs\node.EXE Yarn: 1.22.10 - ~\AppData\Roaming\npm\yarn.CMD npm: 8.1.0 - C:\Program Files\nodejs\npm.CMD Watchman: Not Found SDKs: Android SDK: API Levels: 26, 29, 30 Build Tools: 28.0.3, 29.0.2, 30.0.3, 32.0.0 System Images: android-30 | Google APIs Intel x86 Atom, android-30 | Google Play Intel x86 Atom Android NDK: Not Found Windows SDK: Not Found IDEs: Android Studio: Version 2020.3.0.0 AI-203.7717.56.2031.7784292 Visual Studio: Not Found Languages: Java: 1.8.0_312 - C:\Program Files\OpenJDK\openjdk-8u312-b07\bin\javac.EXE npmPackages: @react-native-community/cli: Not Found react: 17.0.1 => 17.0.1 react-native: 0.64.3 => 0.64.3 react-native-windows: Not Found npmGlobalPackages: react-native: Not Found react-native-pager-view : 5.4.6 expo: 43.0.3
Description
My nested flatList is not showing using pager view.
I have a parent vertical flatlist with an horizontal tab view child, and each tab view has a vertical flatlist but they are not displayed and error "VirtualizedList: Encountered an error while measuring a list's offset from its containing VirtualizedList." is shown.
react-native 0.64.3, react-native-pager-view : 5.4.6
Reproducible Demo
- Create parent vertical FlatList
- Add horizontal ViewPagerAndroid
- Each tab has a vertical FlatList
I'm getting this one too... with the same setup.
I have yet to find a work around.
Does anyone know how this can be resolved?
There error under the hood is:
Trying to measure a view using measureLayout/measureLayoutRelativeToParent relative to an ancestor that requires custom layout for it's children (RNCViewPager). Use measure instead.
It has something to do with RNCViewPager but I have no clue what the "requires custom layout" means.
same error, any resolutions?