From 46f24495221803b7a945883cb8fb262b14f1ea52 Mon Sep 17 00:00:00 2001 From: Ruben Bridgewater Date: Wed, 13 Mar 2024 17:28:17 +0100 Subject: [PATCH] bench: fix array creation in benchmark --- benchmark.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark.js b/benchmark.js index c9464a6..1f20cf9 100644 --- a/benchmark.js +++ b/benchmark.js @@ -5,7 +5,7 @@ const suite = new Benchmark.Suite() const stringify = require('.').configure({ deterministic: true }) // eslint-disable-next-line -const array = Array({ length: 10 }, (_, i) => i) +const array = Array.from({ length: 10 }, (_, i) => i) const obj = { array } const circ = JSON.parse(JSON.stringify(obj)) circ.o = { obj: circ, array }