News for hackers. Stuff that matters.
Re:JavaScript Array.push is 945x faster than Array.concat by apk-d on Thursday May 23, 2019 @06:07PM (#19996509)
> This stuff isn't even worth thinking about.

If more front-end developers have this mindset, I'm beginning to understand how the web (and the desktop, via electron and such) has become the embarrassingly slow and unusable mess that it is nowadays.

Re:JavaScript Array.push is 945x faster than Array.concat by ng12 on Thursday May 23, 2019 @06:09PM (#19996533)
I can promise you the JavaScript runtime is not the cause of whatever "slow and unusable mess" you've experienced.
Re:JavaScript Array.push is 945x faster than Array.concat by pdimitar on Saturday May 25, 2019 @07:12AM (#20008321)
True, but these things add up. It is definitely not a problem at one spot; make those spots 100 and the problem manifests itself very obviously.

I am a fan of expressive and readable code as well and have fully migrated to functional languages in the last 2-3 years. But I don't think in JS we have the luxury to ignore a 945x performance improvement on a very low-level building-block function. It's used in thousands of places.

So you know, I agree with your premise. As a compromise I'd make an utility that reads much better than `Array.push` but still uses it internally (if such a tool does not already exist).