import react, {Children, ReactNode} from 'react' import Project from '../../data/Project' type TimelineCardProps = { children: ReactNode } function TimelineCard({ children } : TimelineCardProps) { let titles : ReactNode[] = [] let childrens : ReactNode[] = [] Children.forEach(children, (c) => { if (c.type.name === "TimelineCardSummary") { titles.push(c) } else { childrens.push(c) } }); return (
{titles}
{childrens}
) } export default TimelineCard