Tuesday 5 January 2021

Animated FlatList in Expo having odd offset values in android

I used the templates I could find to build a scrolling picker for expo. It works perfectly well in ios and the emulators I've tried.

Here's a snack:

https://snack.expo.io/@rezold/animated-listview-offbypixels-for-android

It does not work properly in android. The offset seems to degenerate as I scroll through the list, so I'm not quite in control of where my rendered items are showing up.

I want to use two of these scrollers side by side and they end up looking completely awful because the vertical centering is completely off. Here's a screenshot example of what it looks like in the snack using my Pixel 3:

Vertical Centering is off on Pixel 3

Anyone have any idea what I might do different?



from Animated FlatList in Expo having odd offset values in android

No comments:

Post a Comment