Reactjs – Which syntax is correct for this generic TypeScript React
My component should map through a list where all elements are same type. In props I give list and function which returns JSX element interface ListProps<T>{ items: T[]; renderItem: (item: T) => ReactNode; } const List = <T>(props: ListProps<T>) =>…