/* Copyright (C) 2024 Manuel Bustillo*/ export default function TableOfContents({ headers, caption, elements, rowRender }: { headers: string[], caption: string, elements: Type[], rowRender: (element: Type) => JSX.Element }) { return (
{headers.map((header) => ( ))} {elements.map((element) => rowRender(element))}
{caption}

There are {elements.length} elements in the list

{header}
) }