iamshaunjp / Complete-React-Tutorial

All course files for the Complete React Tutorial on the Net Ninja YouTube channel.
1.77k stars 1.7k forks source link

Lesson 31 #39

Closed osamaayub closed 3 months ago

osamaayub commented 3 months ago

When deleting a blog in blogDetails Component it gives blogs.filter is not function const handleDelete =() => { fetch(${ApiUrl} ${blogs.id}, { method: "DELETE" }).then(() => { setDeleteBlogs((blog=>blog.id!==id)); navigate('/'); }) .catch((err)=>{ console.log(err.message); }) }

osamaayub commented 3 months ago

The issue has been resolved.