Javascript – DELETE Swagger API entry with JS
I'm trying to delete entry [i] from Swagger API with a button. function deleteWork(id) { fetch("http://localhost:5678/api/works/" + id, { method: "DELETE", headers: {"Content-Type": "application/json"}, body: JSON.stringify( { "id": id }) }) } The following code is inside a for loop,…