0
0
mirror of https://github.com/sveltejs/svelte.git synced 2024-11-22 03:47:27 +01:00
svelte/benchmarking/compare/runner.js
Rich Harris 331925356e
chore: add pnpm bench:compare script (#12099)
* WIP compare script

* WIP

* fix

* add script

* update

* fix

* tweak

* fix

* update

* add TODO

* compare

* tmp

* gah

* revert

* fix

* fix

* prevent div/0

* reenable benchmarks

---------

Co-authored-by: Dominic Gannaway <dg@domgan.com>
2024-06-20 10:05:11 +01:00

11 lines
224 B
JavaScript

import { benchmarks } from '../benchmarks.js';
const results = [];
for (const benchmark of benchmarks) {
const result = await benchmark();
console.error(result.benchmark);
results.push(result);
}
process.send(results);