<script src="https://unpkg.com/c-promise2"></script>
<p>Make request to endpoint with 10s+ latency</p>
<p>Open your console to see the log</p>
<p>Note that the related request does abort when you undo the promise chain (see the network tab in developer tools)</p>
<button onclick="request(0)">Request url</button>
<button onclick="request(5000)">Request url with 5s timeout</button>
<button onclick="abort()">Abort</button>