7 ms·
Reading about accessibility on a website that uses JavaScript and <button>s for navigation is a tad ironic.
by merlinscholz 6y ago
Reading about accessibility on a website that uses JavaScript and <button>s for navigation is a tad ironic.
- henriquez 6y agonot to mention the page is completely broken (no content) with JavaScript disabled. The article still brings up good advice, for whatever it's worth.
- deleted 6y ago[deleted]
- coldpie 6y agoNot even the links along the top work without JS, I guess the temptation to re-implement the <A> tag in JavaScript was too strong. Their re-implementation doesn't even support middle-clicking to open in new tabs.
- kevincox 6y agoThis is one of my top three annoyances on the web. Soooo many people re-implement links but don't realize that you can do more with links than just follow them. What about copy url, open in new tab, open in new window, share, ... Just use an <a> tag! And if you really need to carefully prevent only left clicks to do internal navigation. (I do wish that <a> tags had a better semantic event that could be used to override only "regular navigation")
- Nadya 6y agoA lot of issues like this are to solve problems for less tech-savvy people or are more about poorly thought and untested ideas about how to make browsing easier. Or at least, that's the intention/reasons given by the project managers and clients for why they want things done a certain way. For example opening external links in a new tab is one such common practice. It is done so that people don't lose the page they were on (which is what the Back button is for) because clients are afraid once the user navigates away from their website they won't know how to return to it. But the back button is one of the most used browser features in the browser [1]. If users wanted to open the link in a new tab the browser has the functionality to let them control that behavior but "some people may not know to M3 click, shift+click, or right click->open in a new tab". So instead it is forced for everyone with no way to opt-out without running a userscript that strips out target="_blank" from all <a> elements. And <a> elements are just one of the many cases where "We know how the user wants to interact with our site/the internet as a whole" is often and annoyingly wrong. [1] https://ux.stackexchange.com/questions/36017/is-the-browser-back-button-still-the-second-most-used-navigation-feature https://ux.stackexchange.com/questions/36017/is-the-browser-...
- astura 6y agoI can't even fathom what sort of though pattern leads to "I'll load my entire plaintext blog using javascript." I would really like to know why people do this.
- cglong 6y agoI've considered doing this to make inlining of interactive components easier. Agree though that it seems like overkill.
- CivBase 6y agoThe allure of the SPA. In theory it reduces load times (except for the inital page load) by preventing users from re-loading the same set of base resources for each subsequent page. In practice, it results in a bloated initial page request and requires devs to re-implement a ton of functionality normally handled by the browser (and they inevitably overlook things). I've worked on a couple projects where team members insisted we implement the web interface as a SPA and it has always resulted in an inferior user experience IMO.
- slx26 6y agoIdeally, making efficient websites shouldn't be that crazy: you only want to minimize roadtrips, minimize the size of the content to transfer, and maximize caching. With http and html alone, you can't really do this. The caching is too coarse, and the html can't be parametrized and reused efficiently. If I dared to call myself an engineer, I'd be very angry with this situation. Anyway. With javascript you can get there. Not like most of these pages actually do this; in fact, they generally end up doing x500 more roadtrips, but hey... what I want to say is that I hate javascript and I still feel tempted to do things like this. Most frameworks end up at the middle of the road, using "reusable/parametrizable components" or whatever you want to call it, people use those frameworks and we call it a day.
- tomlagier 6y agoThis is a very good summary of the state of the front end.
- praestigiare 6y agoYeah, it was funny to see a complaint about the flash of unstyled content on a plain text page that needed a loading screen, too. That said, I can't argue with the conclusion, SVG is a better choice.
- happymellon 6y agoIt is now. But we had broken SVG for so long, and people have long memories, and Google search has an even longer history. See also Linux users distrust of Microsoft.
- lucideer 6y agowth I've seen a lot of weird antipatterns on the web, but this is my first time seeing this. What's the point of doing this???
- traveler01 6y agoI don't now, people get insane when using JavaScript based frontends...
- cglong 6y agoIt also seems to break the "swipe to go back" functionality in Chrome and Edge?
- greggturkington 6y agoMuch of the text color contrast is too low to pass WCAG 2 AA as well
- dang 6y ago"Please don't complain about website formatting, back-button breakage, and similar annoyances. They're too common to be interesting. Exception: when the author is present. Then friendly feedback might be helpful." https://news.ycombinator.com/newsguidelines.html https://news.ycombinator.com/newsguidelines.html