Skip to content

Instantly share code, notes, and snippets.

@mousavian
mousavian / axios-vs-superagent.js
Last active January 23, 2018 06:59 — forked from natesilva/axios-vs-superagent.js
Compare performance of Axios vs. SuperAgent when running under Node.js
const HttpAgent = require('agentkeepalive')
const superagent = require('superagent')
const Benchmark = require('benchmark')
const axios = require('axios')
const http = require('http')
var suite = new Benchmark.Suite()
const targetUrl = 'http://httpbin.org/ip'
const axiosInstance = axios.create({
baseURL: 'http://httpbin.org',