HTML Preparation code:
AخA
 
1
<script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
Tests:
  • xhr

     
    const xhr = new XMLHttpRequest();
    xhr.open('GET', 'https://www.googleapis.com/discovery/v1/apis');
    xhr.onload = () => console.log(JSON.parse(xhr.responseText));
    xhr.send();
  • fetch

     
    fetch('https://www.googleapis.com/discovery/v1/apis')
      .then(response => response.json())
      .then(console.log)
  • axios

     
    axios.get('https://www.googleapis.com/discovery/v1/apis')
      .then((response) => response.json())
      .then(console.log); 
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    xhr
    fetch
    axios

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 4 days ago)
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/18.3.1 Safari/605.1.15
Safari 18 on Mac OS X 10.15.7
View result in a separate tab
Test name Executions per second
xhr 1261.1 Ops/sec
fetch 1206.6 Ops/sec
axios 1231.9 Ops/sec