Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not able to set gap with multiple columns contentContainerStyle and columnWrapperStyle #1456

Open
umangloria opened this issue Dec 27, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@umangloria
Copy link

umangloria commented Dec 27, 2024

Current behavior

I have a grid list with 3 columns where I am rendering images in each item. I want to have gap of 2 between items.
On regular Flatlist from React-Native, All I need to do is to use following code:

numColumns={3}
contentContainerStyle={{ gap: 2 }}
columnWrapperStyle={{ gap: 2 }}

However the same code is not working if I swap FlatList with FlashList, It starts complaining that gap is not supported property.

Expected behavior

Above mentioned code should work fine with the FlashList as well just like FlatList

To Reproduce

Platform:

  • [*] iOS
  • [*] Android

Environment

 "@shopify/flash-list": "1.6.4",
 "expo": "^51.0.37",
"react": "18.2.0",
"react-native": "0.74.5",
@umangloria umangloria added the bug Something isn't working label Dec 27, 2024
@umangloria umangloria changed the title Not able to set gap with multiple columns th contentContainerStyle={{ gap: number }} columnWrapperStyle={{ gap: number }} Not able to set gap with multiple columns contentContainerStyle and columnWrapperStyle Dec 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant