3 ms·
But that's not really the the slow part. JavaScript with V8 is one of the fastest interpreted languages. A bare Electron app starts pretty fast. Google wants to
by solarkraft 4y ago
But that's not really the the slow part. JavaScript with V8 is one of the fastest interpreted languages. A bare Electron app starts pretty fast. Google wants to have the fastest browser, so they invest a lot into Chromium (which Electron uses).
Even React isn't all that slow. If you look at benchmarks you may be impressed by how quickly it can do some operations. It's consistently a bit slower than other frameworks, but not that far off. There are (big) React apps that are quite fast, too.
So writing performant applications with these technologies isn't impossible.
Yet a lot of apps built with them are slow. The fast ones are rare.
I don't know what it is yet (happy to be pointed somewhere), but I'm fairly convinced that these technologies have common footguns that encourage programming things in slow ways. I can imagine it being related to React's coarse-grained and easy mismanage reactivity and wonder how much of an improvement Solid is in comparison (it is also functional, but is built to always recompute as little as possible rather than saying "whatever, it's cheap", which React does).
- BuzzwordChief 4y ago> JavaScript with V8 is one of the fastest interpreted languages. It is absurdly slow compared to any compiled language. > Even React isn't all that slow. Yes, it is. > I don't know what it is yet (happy to be pointed somewhere) [..] It is using a web browser to show some text and images.
- gct 4y agoI don't like Javascript but you're mistaken on the performance part, even I have to give the JIT people props for how fast they've made the language in general.
- BuzzwordChief 4y agoIt is not about the interpreter. You just can't express performant code in these languages. JIT compilation makes Javascript faster, but it is not by any metric "fast".
- culi 4y agoDepending on specific use-case, today's JavaScript code is only 2–7 times slower than corresponding C++. That's pretty damn fast. Faster than some compiled languages. Fast enough that if you wanted to obsess over performance you can build the fastest backend framework in Node.js[0][1] [0] https://www.techempower.com/benchmarks/#section=data-r21&test=composite https://www.techempower.com/benchmarks/#section=data-r21&tes... [1] https://just.billywhizz.io/blog/on-javascript-performance-01/ https://just.billywhizz.io/blog/on-javascript-performance-01...
- mpweiher 4y agoHmm...2-7x slower is slow, and that's almost certainly after warmup. Just to put it in perspective: the new Team's startup time is ~9 seconds. At 7x faster, it would be slightly above 1 second, which would be OK.