News for hackers. Stuff that matters.
Re:Browsers are pretty good at loading pages by greenhatman on Sunday July 21, 2019 @06:39PM (#20494114)
It's not as fast as https://dev.to/, which is an SPA. I.e. client side routing.
Re:Browsers are pretty good at loading pages by detaro on Sunday July 21, 2019 @06:55PM (#20494193)
And it took me 2 minutes clicking around to break its idea of the page state. I am partially scrolled down the home page, and it just decided to deactivate scrollbars and the ability to scroll.

A great example of how it's quite difficult to reimplement stuff that works perfectly well on traditional pages.

(At least they seem to haven gotten rid of some of the dark patterns they had in the past, that's nice to see)

EDIT: and within a minute more found another state bug :D

Yes, you can make perfect SPAs, but many people fail and it's a good question if the effort required to do it properly is worth it.

Re:Browsers are pretty good at loading pages by greenhatman on Sunday July 21, 2019 @07:43PM (#20494412)
I've never found a bug on there, and I've been on it many times.

I'd love if you can show me how to reproduce this bug.

I just don't have this experience with SPAs breaking. I actually have no idea where it's coming from.

Re:Browsers are pretty good at loading pages by wvenable on Monday July 22, 2019 @12:50AM (#20495405)
I just reproduced it following the commenters instructions -- clicked the sidebar link, got a popup, pressed the back button and I have no scroll bar.

I can see what is happening there: the popup removes scrolling (because of the overlay) but the back button doesn't restore it.

This certainly does lend to the conclusion that managing page state in a SPA is not trivial.

Re:Browsers are pretty good at loading pages by detaro on Sunday July 21, 2019 @08:30PM (#20494602)
It doesn't happen 100 % of the time, but right now going to the homepage, clicking one of the listings in the "newest listings" box, and then returning to the homepage through the browser back button triggered it.
Re:Browsers are pretty good at loading pages by nkurz on Sunday July 21, 2019 @10:05PM (#20494908)
I am able to reproduce this bug with Safari on a Macbook. I clicked on an item in "newest", then quickly pressed Cmd-Left to return to the previous "page". The front page reappears, but I'm unable to scroll with arrow keys or trackpad. An additional press of Esc returns the expected functionality.

It seems to be a fast and responsive site when it works, though.

Re:Browsers are pretty good at loading pages by nathan_long on Monday July 22, 2019 @06:35AM (#20496736)
> It seems to be a fast and responsive site when it works, though.

LOL.

Y'all, I love speed as much as anyone, but your development priorities should be 1) it works and 2) it's fast.

Using HTML links where 1) is never in doubt and all focus can be placed on 2) seems like good engineering to me.

Reinventing browser navigation is like building a rocket. You should be really, really sure that you need to do it before you try.

Re:Browsers are pretty good at loading pages by wlesieutre on Monday July 22, 2019 @12:55AM (#20495417)
Ah, the good old “footer at the bottom of an infinitely long page.”

Facebook and Google used to be guilty of this, but it’s been a while since I ran into that particular brand of user-hostile web design.

Re:Browsers are pretty good at loading pages by wlesieutre on Monday July 22, 2019 @09:09AM (#20497630)
Addendum - I may have been too harsh here. The page most likely is not infinite. You should able to scroll through the entire backlog of dev.to content to access the footer.

Seriously though, you can't just bolt infinite scrolling into the middle of an existing page if you have content at the bottom.

If anyone's curious, the footer contains: Home, About, Privacy Policy, Terms of Use, Contact, Code of Conduct, DEV Community copyright 2016 - 2019

They've duplicated most of that (but not the copyright) in the sidebar's "Key Links" box, so it's not as big a problem as I've seen on other sites.

If they hadn't, I wonder about the legal implications of making your privacy policy, terms of use, and copyright notice completely unreachable. And why keep them in the footer if you never leave it on screen long enough to click it? Just a "not my job" issue with whoever implemented the continuous scroll? Clearly someone thought about it long enough to put the links somewhere reachable, but not long enough to get rid of the old ones?

Re:Browsers are pretty good at loading pages by tener on Sunday July 21, 2019 @06:58PM (#20494213)
It is fast, but it breaks even faster. Managed to get myself in locked up state in some 15 seconds. Couldn't go back, displayed page was incomplete but no scrollbars were to be seen.
Re:Browsers are pretty good at loading pages by mikeash on Sunday July 21, 2019 @08:30PM (#20494600)
Good: it detects when you’re offline and displays a fun error page.

Bad: this only works on every other click. Half the time the links just silently fail....

Re:Browsers are pretty good at loading pages by StavrosK on Monday July 22, 2019 @09:50AM (#20497930)
For me, it always displays the "you're offline" page.
Re:Browsers are pretty good at loading pages by mikeash on Monday July 22, 2019 @10:16AM (#20498146)
A good demonstration of one of the major hazards of reinventing basic functionality like this: it’s really easy to end up with something that behaves differently on different browsers or just for different people.
Re:Browsers are pretty good at loading pages by couchand on Monday July 22, 2019 @03:20PM (#20501358)
You just reminded me that slate.com frequently tells me I'm offline after clicking the back button.
Re:Browsers are pretty good at loading pages by ldoughty on Sunday July 21, 2019 @09:07PM (#20494711)
How do I access the footer on mobile? It just keeps scrolling it down as soon as it appears
Re:Browsers are pretty good at loading pages by 9HZZRfNlpR on Sunday July 21, 2019 @08:50PM (#20494663)
Scrolling is extremely laggy on latest mid range Android using Chrome. Almost unusable.
Re:Browsers are pretty good at loading pages by StavrosK on Monday July 22, 2019 @09:48AM (#20497917)
That definitely seems faster, I'll give you that:

https://i.imgur.com/bx1LUZD.png

Re:Browsers are pretty good at loading pages by ec109685 on Monday July 22, 2019 @12:16AM (#20495306)
Scroll, click a story, click a link off the site and then hit back button twice. You will jump to top of homepage incorrectly.