JSON Server PATCH

by Jacob King

JavaScript

fetch('http://localhost:3000/users/1', {
  method: 'PATCH',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({ email: '[email protected]' })
})
  .then(r => r.json())
  .then(user => console.log(user));