Open anasvakyathodi opened 4 years ago
There is no /new endpoint's implementation in postRoutes.js.
There is no /new endpoint's implementation in postRoutes.js.
What I meant is... there is a path https://dev-pad.netlify.app/new
where we can upload post
After submitting... there is a message showing successfully submitted...also post fetching function is inside context file, where you can change the data while the submission is success.
Present condition is: After submission, there is no fetching happened after submission... hence no new postes are shown
Okay. Can I work on this then?
Okay. Can I work on this then?
Sure... and if you have doubt of endpoint. This may help:
/
is used as post method in postRoutes.js
It's used in server.js is as
So endpoint will be
/posts/
with post
method
And I don't think backend stuff doesn't need for this issue.
Posts data in the
/posts
path must refresh data after submitting a post in the newpost (/new
) page. Till Now, user have to refresh the posts page after submitting post.