function deleteComments() {
    fetch('/delete-comments', {method: 'POST'})
      .then(response => response.text()).then((data) => {
      getComments();
    })
}
/**
 * Makes a POST request to delete all the comments from
 * the datastore and then reloads the page.
 */
Makes a POST request to delete all the comments from
the datastore and then reloads the page.
Makes a POST request to delete all the comments from the datastore and then reloads the page .
function deleteComments() {
    fetch('/delete-comments', {method: 'POST'})
      .then(response => response.text()).then((data) => {
      getComments();
    })
}
function deleteComments ( ) { fetch ( '/delete-comments' , { method : 'POST' } ) . then ( response => response . text ( ) ) . then ( ( data ) => { getComments ( ) ; } ) }
Makes a POST request to delete all the comments from
 the datastore and then reloads the page.
Makes a POST request to delete all the comments from the datastore and then reloads the page .