import { styled } from "nativewind"; import type { ComponentType, ReactNode } from "react"; import { FlatList as RNFlatList, type FlatListProps as RNFlatListProps, type StyleProp, type ViewStyle, } from "react-native"; export type FlatListProps = RNFlatListProps; interface StyledFlatListProps { style?: StyleProp; contentContainerStyle?: StyleProp; columnWrapperStyle?: StyleProp; } export const FlatList = styled( RNFlatList as unknown as ComponentType, { className: "style", contentContainerClassName: "contentContainerStyle", columnWrapperClassName: "columnWrapperStyle", }, ) as (props: FlatListProps) => ReactNode;