drfeely.com/website/components/Article.tsx

20 lines
391 B
TypeScript
Raw Normal View History

2023-08-26 02:18:11 +00:00
import { ReactNode } from "react";
interface Props {
title: string;
author: string;
children: ReactNode;
}
const Article = ({ title, author, children }: Props) => {
return (
<article>
<h1 className="text-4xl font-bold font-cormorant m-5">{title}</h1>
<h6 className="text-lg italic m-5">{author}</h6>
{children}
</article>
);
};
export default Article;