Skip to content

feat: add flatlist and sectionlist evals#366

Open
grabbou wants to merge 1 commit intomainfrom
feat/lists-group
Open

feat: add flatlist and sectionlist evals#366
grabbou wants to merge 1 commit intomainfrom
feat/lists-group

Conversation

@grabbou
Copy link
Contributor

@grabbou grabbou commented Mar 14, 2026

Beginning to work on a new group of evals. Will follow-up with a group on FlashList and LegendList. Targeting around 5-7 groups per library to keep it contained.

Comment on lines +23 to +24
<View style={styles.screen}>
<Text style={styles.title}>Inbox</Text>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May not be relevant to this - but one thing to be mindful of

  • On iOS, it usually traverses through the first descendant chain to find the relevant scrollview (it can be nested within other views, but needs to be first). This is used to adjust the scrollview for things like the header large title. The text before the scrollview breaks such functionality.
  • For newer functionality, React Native screens also uses this approach to apply things like bottom tab insets.

So, in general it's better to avoid views before scrollview as usually they are used in a screen

Comment on lines +35 to +42
renderItem={({ item }) => {
return (
<View style={styles.row}>
<Text style={styles.sender}>{item.sender}</Text>
<Text style={styles.preview}>{item.preview}</Text>
</View>
)
}}
keyExtractor={(item) => item.id}
onViewableItemsChanged={handleViewableItemsChanged}
renderItem={({ item }) => {
const isVisible = visibleIds.includes(item.id)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I maybe misremembering, but iirc flat list needs extraData if using state not present in data. Otherwise it may not consistently re-render.

The alternative is to use a context.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants