2 ms·
Does this apply to other JS engines or only V8?
by TwoNineA 7y ago
Does this apply to other JS engines or only V8?
- jakelazaroff 7y ago> JSON.parse('…') is much faster to parse, compile, and execute compared to an equivalent JavaScript literal — not just in V8 (1.7× as fast), but in all major JavaScript engines.
- djsumdog 7y agoI was wondering that too. No mention of Firefox or Safari. There is more than one browser/render engine out there. Don't design for the monoculture.
- jchw 7y agoJavascriptCore, Chakra and Spidermonkey appear in the benchmark...
- djsumdog 7y agoah I totally missed that! It's a link to their other benchmarks under the main graph; easy to miss: https://github.com/GoogleChromeLabs/json-parse-benchmark https://github.com/GoogleChromeLabs/json-parse-benchmark
- kllrnohj 7y agoThe graph in the article itself also has the other engines. You don't have to follow any link.
- jchw 7y agoLook at the chart specifically: > JSON.parse('…') is much faster to parse, compile, and execute compared to an equivalent JavaScript literal — not just in V8 (1.7× as fast), but in all major JavaScript engines.
- yvan 7y agoThere is a graph on the article showing the other JS engines and yes, it parses faster.