Our daily blog post is now working so we can now move on to our edit blog post as well inside of edit
blog post.
All we have to do is take our updated title and content and send it to our back and server inside of
a PUT request.
Remember a PUT request is used any time that we want to update a record with a given I.D. So let's get
to it inside of edit blog post.
I'm going to mark this function as async and then inside of here we'll do in a wait.
Jason server doc put I'll again use a back tick to indicate that I want to use a template string we'll
do slash blog posts slash and then dollar sign curly brace I.D. then to tell Jason server what we want
to use for the updated content we have to provide a second argument.
The second argument is going to be an object with our updated title and content which we already provided
to this function.
So inside of here we'll do title and content like so and that should be at OK.
So I'll save this will then tested this out really quickly so I'm going to edit a blog post number 4
down here so I'll tap on that one I'll tap on edit and then I'm gonna add in a longer title so I'll
do something like.
Updated blog post number 4 I'll then save the post and there we go.
If I go back to the original screen.
Very good.
OK so that's pretty much it.
We've now got full create read update and destroy across our entire blog post dataset.
It's now our application is pretty much complete.
That's pretty much it.
So let's take a pause right here.
We're gonna come back the next video.
We're gonna wrap up on some really important ideas out of this application.