diff options
author | 2022-08-03 19:13:08 -0700 | |
---|---|---|
committer | 2022-08-03 19:13:08 -0700 | |
commit | 440eba7c9bec96849adcf7018ea0371973550bfa (patch) | |
tree | e1b6cac7e300be94018193888aa9a3f8949fe67c /bench/json-stringify | |
parent | cf81ee5f418c4076cd6def7cc9108997da486869 (diff) | |
download | bun-440eba7c9bec96849adcf7018ea0371973550bfa.tar.gz bun-440eba7c9bec96849adcf7018ea0371973550bfa.tar.zst bun-440eba7c9bec96849adcf7018ea0371973550bfa.zip |
[misc] Fix `make headers`
Diffstat (limited to 'bench/json-stringify')
-rw-r--r-- | bench/json-stringify/bun.js | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/bench/json-stringify/bun.js b/bench/json-stringify/bun.js new file mode 100644 index 000000000..dd0f755aa --- /dev/null +++ b/bench/json-stringify/bun.js @@ -0,0 +1,12 @@ +import { bench, run } from "mitata"; + +bench("JSON.stringify({hello: 'world'})", () => + JSON.stringify({ hello: "world" }) +); + +const otherUint8Array = new Uint8Array(1024); +bench("Uint8Array.from(otherUint8Array)", () => + Uint8Array.from(otherUint8Array) +); + +run(); |