4 ms·
I don't understand your hangup about using JavaScript to accomplish tasks that JavaScript is extremely well-suited to do. The idea that you are somehow imposing
by peteforde 2y ago
I don't understand your hangup about using JavaScript to accomplish tasks that JavaScript is extremely well-suited to do. The idea that you are somehow imposing a burden on your visitors is an imaginary constraint which is actively consuming the finite minutes you have on the planet. This is a pyrrhic victory.
I am not advocating using SPAs of any kind, especially in a blog context. However, if there is a library which makes it easy to render MathML, why the hell wouldn't you just use it?
I'm not saying that I've never invented artificial constraints for myself; arbitrary goal posts that literally nobody but me would ever notice much less care about. I am saying that perspective is everything, and that sometimes it can be hard to see from the inside.
This is intended as an expression of care.
- Dalewyn 2y agoThe ideal amount of JavaScript is zero.
- IshKebab 2y agoI disagree. The gov.uk website completely eschews JavaScript at some usability cost, in particular form validation is delayed until way later than it would be if they added just a little JavaScript. It can be quite annoying.
- DoingIsLearning 2y ago> The gov.uk website completely eschews JavaScript at some usability cost I would imagine this was mostly driven by accessibility requirements more so than some ideological rigidity.
- fragmede 2y agoa little bit of the right kind of JavaScript helps accessibility, so it's clearly not
- biofox 2y agoUnfortunately, some people view accessibility as an ideology.
- tzmudzin 2y agoIt’s easy to dismiss the genuine needs of someone else if one’s not impacted though. Ideology or not, exclusion does not help.
- tweetle_beetle 2y agoPerhaps, but, taking the example provided, Gov.uk deals with population scale products funded by taxpayers and which may be exclusively digital. Accessibility as an ideology makes sense in this context, and, I would argue, is morally correct.
- rhubarbtree 2y agoWhy?
- deleted 2y ago[deleted]
- mediumsmart 2y agoI agree and with small single page sites doable but when I need to put a navigation (plus language versions etc) of the site into a mobile layout I have to do the js toggle, or do I?
- account42 2y agoWhy would you need JS for any of that?
- mediumsmart 2y agohow else can I have a fullscreen overlay navigation on a phone from an accessible toggle button? almost forgot to answer the question: because I don't know any better
- Lammy 2y agoActual answer: like this! https://codepen.io/Sfate/pen/kGbLzK https://codepen.io/Sfate/pen/kGbLzK
- mediumsmart 2y agoyep that works thank you - so to get the fullscreen overlay (since we only want it on the phones) a media query - maybe it should be the one gridcell navpage. But maybe the links should be listed for the robots ... if mobile is default/first there would be only one link - yeah maybe this is good.
- endemic 2y agoYou can do a lot with CSS these days: https://css-tricks.com/the-checkbox-hack/ https://css-tricks.com/the-checkbox-hack/
- seanwilson 2y agoOne (unusual) approach I like because of the simplicity is to put all your navigation links in your footer, and the hamburger/menu button in the header is just an anchor link that scrolls down to your footer. Unfortunately, accessible HTML solutions for well established UI patterns like menus and tooltips are still far too difficult to get right (anything that requires JavaScript usually).
- throw_m239339 2y agoI agree, but HTML widgets are not sophisticated enough not to require some amount of scripting for interactivity in many cases.
- ozim 2y agoIt is for documents but we have web apps that are not documents.
- manuelmoreale 2y agoAs a fellow no-JSer (when it comes to personal sites) for me it’s mostly about pushing myself to figure out creative solution using only what’s available within CSS and HTMl, which is a lot these days. It’s a fun exercise.
- loco5niner 2y agoSounds like the fun exercise went 'a bit' too far in this case
- manuelmoreale 2y agoI think it’s up to them to decide. If they’re having fun doing it I don’t think there’s anything wrong.
- deleted 2y ago[deleted]
- edflsafoiewq 2y agoBut all the tasks in the article are totally straight-forward SSG stuff. Why would you do some processing in a build step, but then stop half-way and ship a bunch of JS to the client so they can finish it? That only makes sense if the work is dynamic in some way that it can only be done on the client-side.
- Spivak 2y agoBecause you go where the good tooling is and MathJax is drop-dead simple to integrate on the client.