The results are sorted from fastest (best) to slowest (worst).
Validate a JSON sample by parsing it without doing anything with the result.
command | average time (s) | ratio |
---|---|---|
deno run jsonhilo/empty.js < data/npm.json | 0.262 | 1.000 |
jq -c --stream empty < data/npm.json | 0.370 | 1.412 |
node clarinet/empty.js < data/npm.json | 0.492 | 1.878 |
Count all values in a JSON sample. jsonhilo is tested using both its low- and high- level interfaces.
command | average time (s) | ratio |
---|---|---|
deno run jsonhilo/values.js < data/npm.json | 0.250 | 1.000 |
node clarinet/values.js < data/npm.json | 0.486 | 1.944 |
deno run jsonhilo/values.high.js < data/npm.json | 0.494 | 1.976 |
sh jqcount.sh < data/npm.json | 0.774 | 3.096 |
Transform a JSON sample into jq streamed form. jq should be fastest here.
command | average time (s) | ratio |
---|---|---|
jq -c --stream . < data/npm.json | 0.722 | 1.000 |
deno run jsonhilo/path.js < data/npm.json | 1.168 | 1.618 |
node clarinet/path.js < data/npm.json | 1.546 | 2.141 |