- Android
- iOS
- Web
List
Render a virtualized list with stable item keys.
Engine API NListnayan-ui/components
Example.tsx
| Name | Type | Default | Details |
|---|---|---|---|
| data | readonly T[] | Optional | |
| renderItem | (info: NListRenderItemInfo<T>) => ReactNode | Required | |
| keyExtractor | ((item: T, index: number) => string) | Optional | |
| height | number | Optional | |
| itemSize | number | Optional | Exact row height in logical points, including any separator. |
| estimatedItemSize | number | Optional | Rust measures row content when itemSize is omitted. |
| numColumns | number | Optional | |
| onEndReached | ((info: { distanceFromEnd: number; }) => void) | Optional | |
| onEndReachedThreshold | number | Optional | Distance to the end as a fraction of the viewport height. Default: 0.5. |
| ListEmptyComponent | ReactElement<unknown, string | React.JSXElementConstructor<any>> | ComponentType | null | Optional | |
| onRefresh | (() => void) | Optional | |
| refreshing | boolean | Optional | |
| className | string | Optional | Supported Tailwind-style utilities, resolved entirely in Rust. See the engine README. |