4 ms·
I don't think that's quite true. A huge, huge, amount of effort has to go into JS engines to make them competitive with any sane language. I'm also implying th
by MichaelGG 10y ago
I don't think that's quite true. A huge, huge, amount of effort has to go into JS engines to make them competitive with any sane language.
I'm also implying that the attitude of JS and HTML - ignore errors - seems to carry over into users of those things. The fact that having wrappers like jQuery, which accomplish basic tasks that should have been part of the standard, makes it worse. Look at all the "shadow dom" and other hacks around terrible performance due to HTML's model.
Even poorly written desktop apps don't seem to be as bad as common web dev. I'm not sure that most desktop devs are better trained or care more. It's just harder to screw up.
- pcwalton 10y ago> A huge, huge, amount of effort has to go into JS engines to make them competitive with any sane language. Most people consider Python and Ruby "sane languages", and JS has been running circles around them for years and years. Even the most trivial JS JIT beats CPython and MRI/YARV hands down. > I'm also implying that the attitude of JS and HTML - ignore errors - seems to carry over into users of those things. JS doesn't ignore errors. It throws exceptions for all kinds of illegal operations. And error recovery is not a reason for CSS's performance problems. Of all the wrong reasons I've heard suggested for CSS's performance issues, that is one of the weirdest. > Look at all the "shadow dom" and other hacks around terrible performance due to HTML's model. Shadow DOM isn't really about performance. Are you thinking of virtual DOMs as implemented by React, etc.?
- MichaelGG 10y agoNot my idea of sane (Ruby has a command line option for how it handles string printing...); I was thinking of most more-strictly-typed, compiled language. By error handling I mean scripts don't break the page. Same as HTML - the browser tries to ignore source errors. This sloppiness spills over, I think, into the attitudes of developers. But maybe this is an invalid personal projection. I suppose I mean virtual DOM. In other GUI platforms, can't you usually just provide a command to temporarily stop painting, then resume after you've made changes that need recalculating? But perhaps web dev isn't special; sure there's plenty of terrible server software written and maybe I'm poorly extrapolating from too little experience. The end result is that, day-to-day, I can count on basically every desktop app to be fairly responsive. Whereas loading any given content (low interaction) website has a high chance of feeling sluggish to operate. When the actual functionality of said websites is fairly unremarkable, it makes me think perhaps the platform has some responsibility for it, somehow. Edit: I'll admit I'm armchair engineering. I haven't done serious web dev in over 10 years. Just extrapolating based on some observations and how the JS community seems to be, overall. I might be way off here.