Quick framework over Benchmark.js for when JSPerf is down
npm install benchmark-frameworkA tiny framework for quick benchmarking with Benchmark.js.
Create an HTML doc for your perf tests like this:
``html
`
Open this document in any browser (or multiple browsers!) and observe the perf results in the console.
See also the example in test/test_perf.html.
The benchmark-opt and benchmark-event script types accept any parameter that Benchmark.js can accept for options and events, respectively. For example, will compile that inner code and use it as the onAbort event handler.
The event scripts accept one parameter named event`. You can use this to customize how results are reported.