import type { ComponentType, ReactNode } from 'react'; import type { ResultItemProps, SearchType } from '../../../types/search'; export type SearchResultItemComponent = ComponentType>; export function renderSearchResultItem( SearchResultItem: SearchResultItemComponent | undefined, props: ResultItemProps, fallback: ReactNode, ): ReactNode { if (!SearchResultItem) { return fallback; } return ; }