This package provides a wrapper around Benchmark.js with sane defaults and formatting.
yarn add @smartholdem/benchmarker --dev
import { benchmarker } from "@smartholdem/benchmarker";
benchmarker("utils", [
{
name: "map",
scenarios: require("./map"),
},
{
name: "filter",
scenarios: require("./filter"),
},
{
name: "reduce",
scenarios: require("./reduce"),
},
]);
yarn test
Please see CHANGELOG for more information on what has changed recently.
Benchmarker is an open-sourced software licensed under the MIT.