I made JSON.parse() 2x faster
radex.io
I made JSON.parse() 2x faster
1–10 of 15 posts
Re: I made JSON.parse() 2x faster
#2Re: I made JSON.parse() 2x faster
#3Did they merge it?
Re: I made JSON.parse() 2x faster
#4Re: I made JSON.parse() 2x faster
#5This is a great blog post with few comments. Impressive work. Did they merge it?
Re: I made JSON.parse() 2x faster
#6I quite enjoyed this blog post to be honest
Re: I made JSON.parse() 2x faster
#7Re: I made JSON.parse() 2x faster
#8Re: I made JSON.parse() 2x faster
#9Maybe next you can make the object spread operator faster ;). I was recently bitten by it in a hot loop, thinking it was generally syntactic sugar. Turns out that if I know all the property names in an object, it’s far far faster to just assign them all manually.
Re: I made JSON.parse() 2x faster
#10This is delightful! Maybe next you can make the object spread operator faster ;). I was recently bitten by it in a hot loop, thinking it was generally syntactic sugar. Turns out that if I know all the property names in an object, it’s far far faster to just assign them all manually.
BTW. I recently measured the spread operator in a microbenchmark. Interestingly, while the native spread was faster on Hermes and JSC, it was slower on V8/Chrome, and it's faster there to use `Object.assign()`, i.e.:
['@babel/plugin-proposal-object-rest-spread', { loose: true, useBuiltIns: true }]