Hacker News new | ask | show | jobs
by ari__ 1785 days ago
Hacker News is a phenomenal source of hatred for using modern browser features and standards. Any amount of javascript is defined as bloat and should be strictly optional eye candy - completely disregarding the fact that UI and state management frameworks like React have made developing the sort of advanced applications we demand exceptionally easy.

Does a personal blog need React or Vue? No, and my blog is made by a static site generator (Hugo, specifically). Do most web applications built nowadays need them? Almost 100% of the time for non-trivial applications, yes. You can do it without any JS, but with that same ideology you can also write your desktop applications in x86 assembly.

6 comments

Im 29, never used myspace, really had access to the internet in 2011 & Im still suspect of how much utter crap web dev is deteriorating into.

> completely disregarding the fact that UI and state management frameworks like React have made developing the sort of advanced applications we demand exceptionally easy.

Till this day, no one has given me a straight answer on why they choose react beyond the dubious claims of performance++. Or even why build a web app to begin with. Nor have the users been asked if they want native-like apps on the browser.

I complain but I use react everyday on a web app Im sure no one cares if it loads 400ms faster than a server rendered jinja template.

Now we have massive overhead, npm libraries for everything and only god knows whats going on in the node modules folder, keeping up with the joneses by using Typescript - why use typescript when Java or C# do static typing so well? I can't ask silly plebian questions like that. we are modern is translated to yarn install everything and use VScode and dont forget the babel plugins. Can you imagine being looked down on for preferring plain javascript, the thing that Typescript compiles to, as being archaic?

I'm no old timer but that's some crazy shit.

I'm 37, it really wasn't ever any better. I just don't get the sense of nostalgia people have for the "old web." When I think about it, I remember all the ugly toxicity it all was absolutely plagued with. Software bugs were just as bad if not worse, and platforms were just absolutely silly with nonsense you had to put up with. Just to talk shit to someone who probably didn't deserve it because they did to you all because there wasn't much better to do.

There's very little about my past I would go back to.

> Till this day, no one has given me a straight answer on why they choose react beyond the dubious claims of performance++. Or even why build a web app to begin with. Nor have the users been asked if they want native-like apps on the browser.

The main reason is cross platform compatibility for things that don't need to make system calls. Ultimately I would prefer to distribute statically linked Go binaries that are command line applications, but if I was asked all "UI" would be a REST API with a manual. The market finds web applications are successful and lower the barrier of entry, and so they're made.

> I complain but I use react everyday on a web app Im sure no one cares if it loads 400ms faster than a server rendered jinja template.

With NextJS and server side rendering + static optimization I find that time to first (contentful) paint is the same or faster than Jinja without me having to configure a thing.

> Now we have massive overhead, npm libraries for everything and only god knows whats going on in the node modules folder

npm/yarn provides a pretty good developer experience but the way it accomplishes that is a touch horrifying, I agree. Babel and Webpack I find bring it most of the bloat, which is probably a good thing as you're not shipping those dependencies in production bundles. It definitely chews up storage space on the local machine though.

> keeping up with the joneses by using Typescript - why use typescript when Java or C# do static typing so well? I can't ask silly plebian questions like that.

Just to get out in front of it - I do not like Typescript. I find Typescript to be a waste of time. JS's type system is broken as hell, but in just the right way for web development. It makes it flexible and easy to write. With Typescript I feel like I spend most of my time making the compiler happy instead of generating any value for the business or myself.

> Do most web applications built nowadays need them? Almost 100% of the time for non-trivial applications, yes. You can do it without any JS, but with that same ideology you can also write your desktop applications in x86 assembly.

I would love to see a clear explanation of why this is viewed as true. I've seen this stated many times, but generally in a way that seems framed to an audience already inclined to accept it as true. I've never seen an explanation of this written and framed for people who wrote such applications before things like React or Vue existed, and genuinely don't understand (and want to) why the model they present is viewed as so much simpler.

I've genuinely looked for this, and I've found only either presentations of "here's how it works, doesn't this seem better?" (to which the answer always seems like "no"), or exhortations about how CSS and to some extent HTML are obsolete constructs except as tools to be manipulated by JavaScript.

> I would love to see a clear explanation of why this is viewed as true. I've seen this stated many times, but generally in a way that seems framed to an audience already inclined to accept it as true.

To the credit of those that are skeptical, it is really difficult to explain exactly how much more productive it is without having experienced something it. The closest comparison I can make is how SCSS feels coming from plain CSS - it's like all of the things that you wish were easy are suddenly easy, while still being based off of something that you are familiar and already productive with. For people coming from traditional web development, I find that Svelte is the most comfortable tool for them to learn.

> I've never seen an explanation of this written and framed for people who wrote such applications before things like React or Vue existed, and genuinely don't understand (and want to) why the model they present is viewed as so much simpler.

I wrote such applications before React and Vue existed. I don't think I could ever go back. I would not describe it as a simpler model however - you're effectively writing two applications that communicate together to make one. The benefits you get for that are beyond worth it in my opinion. Assuming that you're using NextJS or something else that removes all of the boilerplate configuration, almost all of that complexity is hidden from you unless you need to modify it.

I don't know if I would be able to do very well explaining it myself, but generally - it allows for a more clean separation between systems. My backend exposes an API that my frontend can communicate with over background HTTP requests. I can swap out that backend on a whim (from Django to Rails to Express to Gin to...you get the picture) as long as it exposes the same API. With traditional web applications, I'd have to port over my templates and structure and state management system.

Most people don't switch backend frameworks on a daily basis though, I know I certainly don't. Some of the things that I enjoy are:

- Easier temporary messages/error handling (flash messages handle a limited version of this in traditional SSR environments) - Greater control of how my data is structured and posted (forms are simple enough once you learn them, but having your data structure dictated by DOM structure is less clean in my opinion) - Handling more complicated state is much easier - making a wizard interface with dynamically added and removed sections/questions doesn't need a large series of separate templates - Component structure is just better to work with than template structure (expanded upon below)

The real selling point for me is removing templating languages from your templates. I don't have to worry about what Jinja considers to be an acceptable replacement for control flow, I'm using a language that I already know and is fully integrated with the entire rest of the environment.

> I've genuinely looked for this, and I've found only either presentations of "here's how it works, doesn't this seem better?" (to which the answer always seems like "no")

Generally speaking, the larger and more complex your business requirements are, the more easily you can justify using an SPA framework. Every presentation I've found on that gives only trivial examples, likely for brevity.

> or exhortations about how CSS and to some extent HTML are obsolete constructs except as tools to be manipulated by JavaScript.

I believe that idea is part of the "make everything JS!" cargo cult. For apps that have very simple interactions, I use plain HTML+CSS and no JS. Use the right tool for the job, and all that. With that same mindset however, I'd be very hard pressed to say that there is no place or justification for the Reacts and Vues and Angulars of the world.

> For people coming from traditional web development, I find that Svelte is the most comfortable tool for them to learn.

That's a helpful endorsement, thank you. I'd found Svelte, and it did look promising and more comfortable.

> I would not describe it as a simpler model however - you're effectively writing two applications that communicate together to make one. The benefits you get for that are beyond worth it in my opinion.

> I don't know if I would be able to do very well explaining it myself, but generally - it allows for a more clean separation between systems. My backend exposes an API that my frontend can communicate with over background HTTP requests.

That's a much better explanation than anything I'd seen before. Every description I'd seen before holds up React and Vue as simpler or easier than traditional web development, and that didn't seem at all accurate. The potential architectural advantage, at a cost of simplicity, makes much more sense.

(I do rather like statically compiled type-safe templates, but at that point, that's a separate question of preferred development language.)

> - Component structure is just better to work with than template structure (expanded upon below)

That's one of the clearest advantages I've previously recognized. The idea of putting the HTML and CSS and JavaScript for a component in one place, and combining that with other components, makes perfect sense to me.

Frankly, the fact that we use frameworks which could provide JS-free options at little to no cost to the downstream developer but don't is more condemnation than anything else I can think of.

> have made developing the sort of advanced applications we demand exceptionally easy

Yes, it's only moderately more difficult than making it in a native app would be, and only significantly more bloated.

No, they're complaining about unwarranted complexity, privacy invasion, and monopolies, in the best tradition of "hackers". The web was a means of really easy self-publishing; we didn't need yet another shitty app platform or had a desire to serve the needs of the likes of CompuServe, AOL, etc because that already existed long before the web.
> that same ideology you can also write your desktop applications in x86 assembly

Coding a desktop application in assembly would be more work than in a high-level language, not less. The criticism against using frameworks such as React where they aren't needed is that it is a lot more work and that the end result is more complex than necessary. It is quite obvious that resume driven development is a thing.

> Hacker News is a phenomenal source of hatred for using modern browser features and standards.

Complaining about JavaScript is mere table stakes! The true path of "the modern web is ruined" discourse on HN starts with complaining about webfonts, and progresses to laments about any styling whatsoever and "why should designers have any say in how a web page on my computer looks." It's pretty hard to top "images were a mistake," but you get extra points in the lightning round if you work in a reference to Ted Nelson.

IPV6 was a colossal mistake, with its 128 bit host addresses.

But IPV4 was also a huge mistake, with its 64 bit host addresses.

We should have stuck with NCP, with its 8 bit host addresses.

Everything started going downhill once there could be more than 256 hosts on the ARPANET.

https://en.wikipedia.org/wiki/Network_Control_Program

> It's pretty hard to top "images were a mistake," but you get extra points in the lightning round if you work in a reference to Ted Nelson.

I really can't wait for the HN rant about how Geminispace has turned into Reddit and now we need to rebuild the web on an even stricter protocol.