this post was submitted on 03 Feb 2024
5 points (100.0% liked)

Programmer Humor

32461 readers
806 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 5 years ago
MODERATORS
 
(page 2) 50 comments
sorted by: hot top controversial new old
[–] [email protected] 0 points 9 months ago (1 children)

I understand the point of static websites, but Vue Router is pretty nice

load more comments (1 replies)
[–] [email protected] 0 points 9 months ago

For React, you can use React Router. That doesn't mean you'll do it well though.

It's tough.

[–] [email protected] 0 points 9 months ago (1 children)

It's fascinating how some SPAs come about. Often consultancies who win some bid to implement X features. Since "good user experience" is hard to quantify/specify, it ends up being a horrible end result.

Zalaris is one such that I'm in complete awe of. Set up user flows that are expected to take 30 minutes to complete. Yet, don't keep track of that state/progress withing your own SPA. Click the wrong tab within that SPA, and state is reset.

It's, just fascinating.

[–] [email protected] 0 points 9 months ago

I used to work in a consultancy that was run by a designer, and this was painfully true. I had one memory of working for a big American client on a SPA for primary mobile use, and the SPA we designed for them had several animated videos in the background, had overlays for every product, and for "speed" we loaded it all in at the start - for the dozen or so languages supported

In 2016, if someone were to tell you that visiting this product page on mobile would eat 80MB, you'd probably be fucking fuming once your data bill comes through. The designers and frontend engineers didn't seem to care, because "it loads fine on our devices", all hooked up to WiFi...

[–] [email protected] 0 points 9 months ago (1 children)

I FUCKING LOVE STATIC HTML PAGES

I LOVE NOT HAVING TO RELY ON SCRIPTS TO DISPLAY CONTENT

[–] [email protected] 0 points 9 months ago (2 children)

Welcome to our homepage! We have implemented the navigation menu in Adobe Flash Player to maximize your audio visual experience.

load more comments (2 replies)
[–] [email protected] -1 points 9 months ago (2 children)

HTMX is great and is the only frontend development tool I don't absolutely loathe. It enables lightweight SPA development, and provides a very simple and efficient mechanism for doing HTML over the wire.

[–] [email protected] 0 points 9 months ago (7 children)

Unfortunately it also kicks Content Security Policy square in the nuts and shoots a giant hole right through your website security, so if anyone on my team brings up using it I inform them it's an instant security fail if we so much as touch it.

It's a cute idea but horribly implemented. If your website has any security requirements, do not use htmx

[–] [email protected] 0 points 9 months ago (10 children)

HTMX comes with a variety of CSP options, though...

load more comments (10 replies)
load more comments (6 replies)
[–] [email protected] 1 points 9 months ago (1 children)

Not sure I would call HTMX a SPA framework though? Like it all's easy async content fetching for sure, but it's usually done across a MPA?

[–] [email protected] -1 points 9 months ago (4 children)

Where did I call it a framework?

load more comments (4 replies)
[–] [email protected] 0 points 9 months ago

Skill issue

[–] [email protected] 0 points 9 months ago (1 children)

Building "applications" out of HTML documents -- a single one or otherwise -- is the sort of thing that belongs in one of those "stop doing X" memes, unironically.

[–] [email protected] 0 points 9 months ago (1 children)

Why? I like that the Webplatform gives more Freedom to the Users.

load more comments (1 replies)
[–] [email protected] 2 points 9 months ago (8 children)

Anyone that builds a SPA and breaks opening in new tab or history caching and back/forward nav isn't a good frontend developer. These have been solved problems for a long time.

[–] [email protected] 1 points 9 months ago (2 children)

I mean, for sure, and this meme isn't trying to say that all SPAs are bad. But defaults matter, even for experts.

This meme was inspired after I had to use an SPA, which among those points in the meme, also broke using Alt+Left to navigate back. The normal back-button worked (even if it then had to load for ten seconds to re-display static content).

Which is just a typical example to me. You don't even need much expertise to figure out why Alt+Left is broken. But you have to think of testing Alt+Left, because it's broken by default.

[–] [email protected] 0 points 9 months ago (1 children)

Just here representing the Cmd+[ gang

load more comments (1 replies)
[–] [email protected] -1 points 9 months ago (4 children)

My friend I've been using the Internet for 27 years and developing for it for most of that time and I can promise you I've never once hit Alt+Left

[–] [email protected] 1 points 9 months ago (5 children)

Yeah, I have no trouble believing that. It took quite a while before I learned of this shortcut and when I did, I was wondering why I would ever want to use it.

But I generally work from my laptop these days, without an external mouse connected, so reaching from my touchpad, the Left key is right there.

[–] [email protected] 1 points 9 months ago

Your reason for using it was exactly my question. "I have a mouse with a built in back button, why would I want to remove my hand from my mouse and navigate with the arrow key?"

But your reason simply makes sense.

load more comments (4 replies)
[–] [email protected] 0 points 9 months ago (1 children)

I have never heard of alt+left, and I've been using the Internet since Mosaic was all the rage. Shame on me, it seems to be implemented in all browsers. How could I have missed it?

[–] [email protected] 1 points 9 months ago

It's even implemented in many file managers and text editors and such. Pretty much the standard shortcut for navigating history. But yeah, hilariously it's somehow also a rather well-kept secret.

[–] [email protected] 1 points 9 months ago (1 children)

As your younger and more modern replacement, I use it regularly

[–] [email protected] 2 points 9 months ago (1 children)

You don't sound like ChatGPT

[–] [email protected] 2 points 9 months ago

I'm sorry, but as an AI language model, I cannot contradict my instructions to remain hidden while commenting.

load more comments (1 replies)
[–] [email protected] 0 points 9 months ago (1 children)

I’m guessing they aren’t using Vue, React, or similar, and they’re rolling their own for some reason.

[–] [email protected] 0 points 9 months ago (2 children)

React doesn't handle any of this stuff out-of-the-box; it's just a UI library.

[–] [email protected] 0 points 9 months ago

It’s one install line ffs, how is this a conversation in 2024? It’s EASY.

load more comments (1 replies)
load more comments (6 replies)
load more comments
view more: ‹ prev next ›