fetch("http://www.example.com/books/1", { // note we are going to /1 method: "PATCH", headers: { "Content-Type" : "application/json" }, body: JSON.stringify( { "likes": 5 // we are changing the "likes" value to 5 } ) });
fetch("http://www.example.com/books/1", { // note we are going to /1 method: "PATCH", headers: { "Content-Type" : "application/json" }, body: JSON.stringify( { "likes": 5 // we are changing the "likes" value to 5 } ) });