adrianhajdin/project_mern_memories

Posts not displaying on the front end (circular progress by default)

outterspacem opened this issue · 0 comments

Hi all,

At the time of creation, I can see the posts displayed on the front end and they even get created in my MongoDB cluster. However when I inspect elements on my browser console, I don't see element get created and when I reload the page I get an infinite spinner (my guess is this is because it cannot retrieve any posts so applies the circular progress by default: !posts.length ? : (

Any ideas what the issue might be?

Thanks

Update: I solved the issue by making sure useEffect(() is under const dispatch = useDispatch(); in App.js