Hacker News new | ask | show | jobs
by _0o6v 2538 days ago
Recently, there seems to be this ever-growing, romantic vision of turning the clock back to a time when the browser was simpler.

Certainly, in terms of accessibility, the JavaScript (and Browser) landscape has never been better than it is now. General awareness and tooling for building online experiences that consider disabled users has led to an infinitely better time for these people when using the internet, overall.

Sure, some people build shitty products that make your fan spin and ignore disabled users. But that's because they've built a shitty product, not because of the 'modern browser' itself.

> The web can be a resource hog, sometimes devouring CPU and memory. But it doesn’t need to be that way.

It also doesn't mean returning back to horse and cart!

2 comments

Whenever I see lines like that, "the web can be a resource hog, sometimes devouring CPU and memory", I really want to respond "no one cares".

OK, not no one. And people certainly DO care if a site is very slow, or user interactions are bogged down and choppy. But there is this somewhat weird (IMO) belief, very common among developers and tech-savvy users, that heavy use of resources is a bad thing in and of itself. I certainly understand where that belief comes from, but it's just not relevant to 98%+ of people if it doesn't get to the point of being heavily noticeable in user interactions.

Heavy use of resources IS a bad thing in and of itself (if it's not necessary for the task being done - I fully expect a game to eat up my CPU and GPU). We're not on DOS with only one application running at a time. If all my resources are being eaten up by bloated websites and Discord and Atom and other crappy Electron apps, that's less resources for other programs that might actually need them.
I can't help but get the feeling the only reason my Google phone has an 8-core processor is so news sites can play more ads.
no one cares

Such a compelling argument! But seriously, MOST websites are slow and bogged down, especially in cheap hardware, we just have grown accustomed. The fault doesn't lie in hardware not being there yet or over-zealous power users, it's in webdevs being just plain lazy. And it's just gonna get worse with each iteration of new js library woo, each one another brick in this clusterfuck of a Babel Tower.

It is bad because if browser uses too much memory then it swaps out other programs like gnome-shell to the point that you cannot use Alt-Tab because the code responsible for it got swapped out.

It would be better if poorly designed sites (for example newspapers or TV channel sites) were slow or displayed without images and iframes with ad rarher than situation when browser swaps out everything else to help this poorly designed site run faster.

> Whenever I see lines like that, "the web can be a resource hog, sometimes devouring CPU and memory", I really want to respond "no one cares".

That's an excellent summary of modern web development. Folks with 32 GB of RAM and the latest and greatest Intel CPU + the most expensive cutting edge video card decide what's acceptable resource usage. Cause hey, it works for me.

A lot of people use portable devices such as laptops or phones: they do care when your website makes their battery last an hour less.
How many people would know what caused it, though? Maybe they spent a while on a few different websites, but only one was a resource hog...
Hoping the user doesn't notice that you've been using their resources has always seemed like an awful gamble to me: both in the sense that you're deceiving your users by pinning the blame on other websites/their browser/their computer in the their mind, and also in the sense that you're just making it more likely that someday users will have access to this information.
It's pretty noticeable which websites hog resources if you use your laptop or phone regularly. People are well aware that streaming and social media apps sinks battery like a boulder compared to looking at a wikipedia article. My macbook is dead in 5 hours or 1 hour depending on if I'm on reddit/hn or content heavy websites. Fans kick into gear when netflix starts streaming and the laptop becomes untouchable. Back when I used messenger on my phone I used to watch my battery percent tick down by the minute.
Imagine how fast our computers would be if all developers tuned for performance and did their best to conserve resources. We've gone from people trying to squeeze every last bit of performance out of an extremely low resource system to the current state of "just go for it, most people have enough resources for my one app I'm developing".

It blows my mind that companies think that delivering a full-featured browser with a web page to make it into a native application makes any sense whatsoever. In a lot of cases, the same app, written 30 years ago, would fit on a floppy disk.

Now imagine how slow development would be in your hypothetical world. Most of the apps and sites you use wouldn't be build because the cost of development would be so high.

We throw tons of CPU and memory at these problems precisely so we can build fast.

And we build fast so that we can make tons of low quality apps. I think we're over saturated as it is.
I thought so too. When I was 16 I moved to a university dormitory. It was flat with 3 rooms and 2 people in each room. I was FreeBSD mega-geek but my roommate was a Linux fan(lately he moved to FreeBSD too). We were writing our own fork of DWM(https://dwm.suckless.org/) with functionality like in hackers films, using text-based clients for email, IRC, ICQ(it was really popular in Russia in that time), lynx, etc. It was like we are a hippie-hackers from 70th with a long hair(my was about 70 cm) and very creepy beards. It was really awesome because of no one except us have on so deep knowledge of networks and Unix systems. We were kings of the local network because the building was new without a local network, so we build it from scratch.

And now, 15 years later ... I have a MacBook Pro and iPhone. I'm so lazy. Every day at work I write tons of C/C++ code. I know how works Linux TCP/IP stack, TLS, HTTP1/2/3. But I just want to watch the new Stranger Things episode after the workday. I don't have any customization app for OS X. No special hotkeys or c00l h4x0r terminal app.