An open API service indexing awesome lists of open source software.

https://github.com/jamen/bench

Better defaults for Benchmark.js.
https://github.com/jamen/bench

Last synced: 11 months ago
JSON representation

Better defaults for Benchmark.js.

Awesome Lists containing this project

README

          

# @jamen/bench

A [benchmark.js][benchmark.js] reporter.

![](./demo.gif)

## Usage

### `benchmark()`

Creates a `Benchmark.Suite` that does the reporting for you. See [benchmark.js's docs][benchmark-docs] for more info.

```js
let bench = benchmark()

bench.add('foobar', () => {
foobar()
})

bench.run()
```

[benchmark.js]: https://github.com/bestiejs/benchmark.js
[benchmark-docs]: https://benchmarkjs.com/docs