function refreshServer() {

  //Api call to the server to refresh the game and reset all values once refresh button is clicked
  // or web page is refreshed.
  fetch('/refreshServer')
    .catch(err => console.log(err));

  counterInPlay = "X";
  counterOpposition = "Y";
  kingPlayer;
  countersX = 12;
  countersY = 12;
  selectedX = 10;
  selectedY = 10;
  commitment = 0;
  doubleTakeIndicator = 0;
  doubleTakeLocation = 0;

  $(`#checkersBoard`).show(1000);
  $(`.gameOver`).hide(1000);
}
/**
 * @function refreshServer - to refresh the game
 */
@function refreshServer - to refresh the game
@function refreshServer - to refresh the game
function refreshServer() {
  fetch('/refreshServer')
    .catch(err => console.log(err));
  counterInPlay = "X";
  counterOpposition = "Y";
  kingPlayer;
  countersX = 12;
  countersY = 12;
  selectedX = 10;
  selectedY = 10;
  commitment = 0;
  doubleTakeIndicator = 0;
  doubleTakeLocation = 0;
  $(`#checkersBoard`).show(1000);
  $(`.gameOver`).hide(1000);
}
function refreshServer ( ) { fetch ( '/refreshServer' ) . catch ( err => console . log ( err ) ) ; counterInPlay = "X" ; counterOpposition = "Y" ; kingPlayer ; countersX = 12 ; countersY = 12 ; selectedX = 10 ; selectedY = 10 ; commitment = 0 ; doubleTakeIndicator = 0 ; doubleTakeLocation = 0 ; $ ( ` ` ) . show ( 1000 ) ; $ ( ` ` ) . hide ( 1000 ) ; }
@function refreshServer - to refresh the game
@function refreshServer - to refresh the game
//Api call to the server to refresh the game and reset all values once refresh button is clicked // or web page is refreshed.