import { Card, CardHeader, CardBody, CardFooter } from 'reactstrap'; import { FC, ReactNode } from 'react'; import './ChartCard.scss'; interface ChartCardProps { title: Function | string; footer?: ReactNode; } export const ChartCard: FC = ({ title, footer, children }) => ( {typeof title === 'function' ? title() : title} {children} {footer && {footer}} );