add prop to ListImpl for disabling content-visibility style (#4236)

* add prop to `ListImpl` for `content-visibility` style

* change to `disableContentVisibility`

* lint

* tweaks

* Keep the fix more general

* Clarify ambiguity

---------

Co-authored-by: Dan Abramov <dan.abramov@gmail.com>
This commit is contained in:
Hailey
2024-05-29 20:09:24 -07:00
committed by GitHub
parent eb6f44853d
commit 9628070e52
3 changed files with 21 additions and 4 deletions
+2
View File
@@ -26,6 +26,8 @@ export type ListProps<ItemT> = Omit<
onItemSeen?: (item: ItemT) => void
containWeb?: boolean
sideBorders?: boolean
// Web only prop to disable a perf optimization (which would otherwise be on).
disableContentVisibility?: boolean
}
export type ListRef = React.MutableRefObject<FlatList_INTERNAL | null>