Live data from Hacker News

Advice to Young Web Developers

tumblr.beesbuzz.biz

31–40 of 328 posts

Re: Advice to Young Web Developers

#31
post #19

Why so much hate for infinite scrolls? What if your content is "infinite". I can't see a better way to handle that.

Infinite content can still be paginated, grouped, or whatever you like. For example think of Google search results.

Pagination gives mental boundaries, navigation markers and shortcuts to items.

Reading through infinite scrolling is psychologically addictive for a few reasons.

Another complaint about infinite scrolling is more technical: Implementations tend to forget your location, and/or significantly change the data when you return to the page. So if you leave an infinite-scrolling page and come back to it, you often can't continue from where you branched off.

In addition to not remembering the position and state, sometimes scrolling back down to where you were before takes a very long time. I've had occasions where I've had to scroll for ~20 minutes to reach an item I knew was there because I'd just seen it a few minutes prior, and forgot to use the "open in new tab" workaround when clicking on it.

My bank's phone app is bad for this. Scrolling through my transaction history takes ages. If I want to look at last month, no problem. If I want to check a transaction from last year, I'll have to scroll down and wait for a bit more to load, over and over and over.... Then if I click the transaction to view details, then return back to the history to look at more, I have to do the whole annoying scroll-and-repeatedly-wait dance all over again. For every transaction I want to look at.

And that's a mobile app not a browser, so no option to "open in a new tab". Mobile apps with all these flaws are horrible.

(Thank goodness browsers provide the "open in new tab" workaround for webapps that have linkable items. Pity it's broken by badly written webapps that don't make items linkable.)

Re: Advice to Young Web Developers

#32
post #19

Why so much hate for infinite scrolls? What if your content is "infinite". I can't see a better way to handle that.

The infinite scroll problem I feel comes up most that if there was a useful piece of information in the middle of an infinite scroll it is likely impossible for you to return there with any sort of reliability. You can't save the URL because it probably doesn't encode anything useful about where you are in a most cases. You can't logically organize 'where' this information is because its location is pure happenstance. It is pointlessly ephemeral. I can't start on page 5, I can't start on page 100. I have to scroll and just pray I get to get lucky which is the function of a slot machine, not someone who's trying to present me information. If I _really_ wanted to get that much more content I am more than happy to click the next button.

Re: Advice to Young Web Developers

#33
> To the developer, “isomorphic” code breaks down the barrier between client and server. To a malicious client, it means they have control over the server too.

Huh? I don't follow this. Sharing some helpful util functions between the frontend and backend doesn't allow malicious clients to control your server.

Re: Advice to Young Web Developers

#34
post #20

I feel like posts like this are just somebody missing the web how it used to be. I mean the Web IS an app platform now.

I didn't get that sense from the post. I took that they were advocating for basic HTML/JS when appropriate. A reminder that it's still a valid way of doing things.

If you're building an app, yeah use React.

If you want to put some contact info on the internet, there's no reason it can't be vanilla HTML.

Or at least that's how I read it.

Re: Advice to Young Web Developers

#35
post #15

Earlier quoted context omitted.

SPAs are an anti-pattern. Let's rebuild html rendering, navigation history, forms, etc, all with Javascript, because it's the hip thing to do.

The way in which we consume and deliver via internet has moved on from the early days of the web. It's no longer just text, images and links. There's much more to it now, and SPAs are a reasonable step forward to providing richer experiences online with more functionality. Not sure you could ever call them an anti-pattern.

> It's no longer just text, images and links.

Assuming you add video, 99% of the web is just text,images,links,forms, and video. None of these things even require Javascript.

Re: Advice to Young Web Developers

#36
post #4

This sounded more like a anti-SPA post. Maybe the title should be "Reasons for not building a SPA".

The most common reasons for building a SPA: * That is the design pattern dictated by your large framework. * Maintaining state is absurdly simple, but it requires original code if not using a big framework. * The browser provides a simple standard API for interacting with HTML, but your framework provides abstractions you didn’t know you could live without. That’s it. Developers twist themselves in knots trying to qu…

I'll offer up another reason, which I feel is a little more accurate:

* Your web app requires heavily interactive bits, such as smart forms, smart tables, previews, content editing, etc. To deliver such functionality in a maintainable way, you use a framework. (As a side note, yes it is possible to deliver this functionality in vanilla JS, but to make it maintainable one must essentially build an ad hoc framework.) Because most frameworks push users towards a SPA, you end up following the path of least resistance and developing a SPA.

Re: Advice to Young Web Developers

#37
post #22

Earlier quoted context omitted.

Nothing pisses me off like getting a message that some website only supports Chrome in 2020

The one that drives me crazy are websites that say they only support safari on iOS... It’s all safari under the hood.

Safari on iOs is a bit special. Some features are missing compared to the Mac version. You also need quite a few safari ios specific code if you want to build a web app. But this is a bit broken since Apple wants you to publish to the appstore and not release web apps anymore.

You also need a Mac to debug safari on iOs. I hate Safari.

Re: Advice to Young Web Developers

#38
post #31
post #19

Why so much hate for infinite scrolls? What if your content is "infinite". I can't see a better way to handle that.

Infinite content can still be paginated, grouped, or whatever you like. For example think of Google search results. Pagination gives mental boundaries, navigation markers and shortcuts to items. Reading through infinite scrolling is psychologically addictive for a few reasons. Another complaint about infinite scrolling is more technical: Implementations tend to forget your location, and/or significantly change the da…

Sure, there are plenty of bad implementations out there, but is that a reason to no use them at all?

A DB tool I made has infinite scroll plus pagination buttons. It updates the pagination buttons while scrolling.

Re: Advice to Young Web Developers

#39

> To the developer, “isomorphic” code breaks down the barrier between client and server. To a malicious client, it means they have control over the server too. Huh? I don't follow this. Sharing some helpful util functions between the frontend and backend doesn't allow malicious clients to control your server.

Guessing he means when the code shared does important things like validation.

Re: Advice to Young Web Developers

#40
post #19

Why so much hate for infinite scrolls? What if your content is "infinite". I can't see a better way to handle that.

The infinite scroll problem I feel comes up most that if there was a useful piece of information in the middle of an infinite scroll it is likely impossible for you to return there with any sort of reliability. You can't save the URL because it probably doesn't encode anything useful about where you are in a most cases. You can't logically organize 'where' this information is because its location is pure happenstance…

You can have infinite scroll + pagination buttons
Post reply on HN