Promise vs BlueBird

Benchmark created by Oleg on


Preparation HTML

<script src="https://cdn.jsdelivr.net/bluebird/latest/bluebird.min.js"></script>

Test runner

Ready to run.

Testing in
TestOps/sec
Promise
function A() {
  return new Promise((res, rej) => {
    res('test')
  })
}

A().then(result => {
  if (result !== 'test') {
    throw new Error('Bad result')
  }
})
ready
BlueBird
function B() {
  return new Promise((res, rej) => {
    res('test')
  })
}

B().then(result => {
  if (result !== 'test') {
    throw new Error('Bad result')
  }
})
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.

  • Revision 1: published by Oleg on
  • Revision 6: published by Micah Thomas on