Generic ListItem in React Native using TypeScript
Xebia
NOVEMBER 10, 2021
In this blog I’ll demonstrate how TypeScript can help to create FlatLists with generic list items. type Props<ItemT> = { data?: This generic type ItemT should be the same type as the type that is passed as an array with the data prop. This is the data that is used for rendering the list of rows.
Let's personalize your content