9 ms·
They are a poor user experience because you don't want to have to load the whole text for cases where the user is only supposed to see some of it at first? If
by adrianratnapala 10y ago
They are a poor user experience because you don't want to have to load the whole text for cases where the user is only supposed to see some of it at first?
If so: then does it make sense to download megabytes of JS libraries in order to save downloading 100kB of text?
- sanderjd 10y agoThat's not what I'm talking about. I'm talking about actions a user is taking. For instance, HN just performed a full page load for me to make this comment, and will do another one after I click "reply", and then I'll have to find my place again. That is sucky and would be much better implemented with javascript and a background POST. This is somewhat ok on HN because actions like commenting are much more rare than passively reading content (and because I find enough value in the commentary here that I'm willing to put up with quite a bit of suckiness), but it is a lot less ok for applications that are a lot more behavior based. To put it in concrete terms, I came to the conclusion that SPAs (or at least using javascript to implement most behaviors on individual pages of a multi-page application) make a ton of sense after spending a few years building an internal line-of-business application with a lot of behavior and not much content as a normal Rails multi-page app, noticing that the user experience was not great at all, and finding it to have very low return on investment to attempt to do it with progressive enhancement. We would have saved a lot of time and money by starting with a JS-based SPA approach for an application like that. If I were building a blog or news site, I suspect the opposite would be true.
- wtbob 10y ago> For instance, HN just performed a full page load for me to make this comment, and will do another one after I click "reply", and then I'll have to find my place again. That's why I comment in a new tab. But yes, I see that as an example where JavaScript could improve an HTML page — but that's no reason to make it impossible to use with JavaScript!