Get Customer Regular/Promise

HTML

<script src="https://cdnjs.cloudflare.com/ajax/libs/axios/0.18.0/axios.js"></script>
<script src="https://getfirebug.com/firebug-lite-debug.js"></script>
<div id="console-log"></div>

CSS

.console-line {
  font-family: monospace;
  margin: 2px;
}

JavaScript

const apiURL = 'https://floating-meadow-81947.herokuapp.com/api'

// Get customer record
function getCustomer(custId) {
  return axios.get(apiURL + '/Customers/' + custId)
    .then(response => {
      console.log(response.data);
    })
    .catch(error => {
      console.log(error);
    })
}
getCustomer(1);