We've been building a hooks based REST API wrapper.
A specific use case discussed in this gist is – how do you close a modal after updating a remote resource completes succesfully?
Which of the following options seems best or is there a better approach altogether?
function EditNoteModal ({ id, onClose }) {