There is truly nothing about any of those that couldn't be done with a simple page refresh. Especially YouTube. Generally I find most of what JavaScript adds just irritating.
There is truly nothing about any of those that couldn't be done with a simple page refresh. Especially YouTube. Generally I find most of what JavaScript adds just irritating.
Our children won't believe we ever browsed the web in a graphical multitasking OS on 64mb of RAM and a single processor core. "Don't be silly, that wouldn't even be 1/6 enough to load Google Inbox!"
* Displaying the video
* Controlling the video (although with the browser's default controls)
* Being logged in
* Listing videos
* Voting
* Commenting
* Suggested videos
* Subscribing
Actually, I can't see a single thing that can't be done without Javascript. It has no complex notification system aside from annotations (and I'm not sure anyone enjoys annotations), nothing that isn't provided by browsers. But no javascript would require page refreshes, which makes for a worse UX. Eh, we survived refreshes before. Maybe browsers could even agree on a standard to refresh only part of the pages by querying the server themselves. Throw in five lines of JS to save to localStorage the current time on the video and restore it on reload.
Ajax was better UX than full page refreshes when it was basically just replacing frames and iframes. It's become bad UX now that template rendering systems and a few hundred KB of code are involved.
Actually, I just tried this with modern Gmail in one tab and the basic HTML version in another. It's way, way faster to switch folders/categories in the basic HTML version. It wasn't even close, despite modern Gmail "efficiently" loading just the data it needs and basic HTML refreshing the whole page.
> Maybe browsers could even agree on a standard to refresh only part of the pages by querying the server themselves.
Maybe browsers could also agree on implementing all needed applications in the browser. Then you just make <youtube> tag and you have implemented youtube.
Also, a tiny bit of JS and no ajax can solve that easily.
> Also, a tiny bit of JS and no ajax can solve that easily.
No disagreement from me that JS solves these issues.
There are edge case clients that would need to contravene this. Most of those clients don't support JavaScript (or in many cases video) in a meaningful way, making the whole thing moot.
No, but in practice all major browsers (Firefox, Chrome, IE, Opera and Safari) do so. And it's not like the implementations of JS and its APIs never differ.
But on the other hand, Youtube wouldn't have as many videos – specifically the content creators wouldn't have as much of an incentive to upload them – without the social features being there.
Depends how you're counting. Using that 100kb of code "as intended" essentially requires Firefox (95MB) or Chrome (153MB), or some proprietary alternative.
To use VLC instead, we can get by with something like dillo (1MB) and youtube-dl (1MB), which (added to your 30MB estimate for VLC) is much less client-side code.
(Size estimates taken from packages.debian.org)
Because then you have the 7GB OS + 95MB Firefox + 100kB YouTube vs. the 7GB OS + 30MB VLC + 2MB youtube-dl
And, additionally, the browser is just a document displayer, like a PDF viewer, or an image viewer. 135MB for that is far too much in any case.
I wish. Either that, or `youtube-dl` became the official UI.