Blog option
unknown
typescript
2 years ago
486 B
5
Indexable
function BlogOption({ blog, setDeleted }: Props) {
return (
<div>
<Link href={`/blog/${blog._id}`}>
<div className="text-blue-700">{blog.title}</div>
</Link>
<button
className="bg-red-500 text-white active:bg-red-600 px-1 mx-2 border border-black"
onClick={() => handleDelete(blog._id, setDeleted)}
>
delete
</button>
<button className="px-1 border border-blue-800">Edit</button>
</div>
);
}Editor is loading...