(评论)
(comments)

原始链接: https://news.ycombinator.com/item?id=43422162

Hacker News 上的一个帖子讨论了前端 (FE) 开发中快速变化和废弃的步伐,并将其与 Rust 等后端 (BE) 技术的相对稳定性进行了对比。原发帖人哀叹前端框架和工具需要不断更新和重写。 评论者表达了类似的挫败感,他们争论 React 和 Angular 等框架的寿命和必要性。一些人认为框架很快就会过时,需要不断学习和适应,而另一些人则认为某些框架,如 React,仍然可行。 有人提出了替代方案,包括服务器端渲染、最小化 JavaScript 使用以及采用更简单的技术,如 Phoenix LiveView 和 Alpine.js。一些人认为解耦前端和后端团队会加剧这个问题。一些人建议完全放弃框架。大家普遍认为不断重写代码以跟上最新框架的步伐并非良策。甚至有人指出,作者自己的网站使用了过时的主题,突显了这个问题的普遍性。

相关文章
  • (评论) 2024-02-08
  • 前端的跑步机 2025-03-20
  • (评论) 2023-11-07
  • (评论) 2025-02-23
  • (评论) 2024-05-05

  • 原文
    Hacker News new | past | comments | ask | show | jobs | submit login
    The Front End Treadmill (polotek.net)
    40 points by Kerrick 34 minutes ago | hide | past | favorite | 22 comments










    I have recently been doing some upgrades to the build system for our FE code to swap out yarn for pnpm. I’m normally a backend engineer, but I’ve spent plenty of time in the JS mines.

    The most frustrating thing about dipping in to the FE is that it seems like literally everything is deprecated. Oh, you used the apollo CLI in 2022? Bam, deprecated, go learn how to use graphql-client or whatever, which has a totally different configuration and doesn’t support all the same options. Okay, so we just keep the old one and disable the node engine check in pnpm that makes it complain. Want to do a patch upgrade to some dependency? Hope you weren’t relying on any of its type signatures! Pin that as well, with a todo in the codebase hoping someone will update the signatures.

    Finally get things running, watch the stream of hundreds of deprecation warnings fly by during the install. Eventually it builds, and I get the hell out of there.

    It’s just nuts to me the degree to which FE development as a whole seems to embrace the breaking change, the deprecation, etc. I’ve been working on a large rust project for nearly four years and in that time there have been a few minor breaking changes in or of third party libraries, but only one major breaking change that required significant changes to our application. Meanwhile in JS it seems like you can’t go more than six months without having to rewrite something. It’s bananas.

    Okay, rant over.



    > Whatever framework you choose will be obsolete in 5 years.

    I've been writing React professionally for over a decade at this point. I don't know what this guy's on about.



    Component lifecycle methods to hooks and HOCs, does that ring a bell?


    Yeah, and I'm not anywhere near as distressed about it as this article implies I should be.


    As a BE engineer when that happened, I had just started to become proficient in it, coming from Angular. I threw in the towel and went back to my backend world of peace and happiness. So he's not alone, these deprecations are insane.



    I've been writing React professionally for over a decade and react from 5 years ago is obsolete. Like, literally won't build with current tools. To their credit, I think the React code itself has maintained reverse compatibility pretty well (it's not React's fault), but the build systems I was using 5 years ago have all changed and broken reverse compatibility.

    Even a well-maintained project like React can't escape the squalor of its ecosystem.

    I don't always have this option, but usually these days I choose vanilla JS, imported with no build system, do as much as I can with Python/Django on the backend, and opt out of the JavaScript ecosystem entirely. I haven't regretted it.



    Didn't React deprecate itself entirely circa 2018?


    They just keep stirring his slop and he keeps eating it, that's all I'm reading here


    Why does FE development have such churn? Desktop toolkits from 30 years ago work just as performantly today; what is so difficult about the browser that demands constant framework updates?


    To jump off the treadmill is not using a fronted framework: at all, and not using a random one and not rewriting the code later. Server side rendering, JavaScript only when needed, no separation between backend and frontend folks in the company.


    No separation between backend and front end is hard. I’m not good at front end, and we don’t have a designer. I’m miles better on backend though and other team members are more talented than me for front end design.


    Speaking of front end frameworks, whatever happened to Angular(JS)? It seemed to be required on every other job posting, but now things seem to only ask for React or React Native.


    Based on the first paragraph alone, almost all devs I know think that a complete rewrite will solve all the issues, thats not only frontend but backend too.

    Web development in its current form is a beast and if we want true change we need to fix the biggest issue there is for all of webdev: Forcing everything into Javascript and incompetence. I wont claim I am competent, but at least I acknowledge that SvelteReactVueSolidNextNuxt is not the solution but rather trying to patch up some symptoms... The Web needs true change.



    > Whatever framework you choose will be obsolete in 5 years.

    IDK our product is older than 5 years and React is still not obsolete.



    Giving up on that treadmill after investing 3 insanely intense years consuming everything about it was the best thing I ever did. Now I write elixir (phoenix liveview), sometimes I write javascript (phoenix hooks), sometimes that javascript uses Alpine. Zero pain.

    I have never felt more vindicated understanding HTTP, Hypermedia, and HATEOAS than I have in the last three years.



    Amen!


    > But our current framework layer is working against the grain instead of embracing the platform.

    Said the person with this bullshit in their page code, which will not deactivate when JavaScript fails to run:

        
    
    Guess who just saw it happen.


    That comes from the theme they’re using, and there’s a noscript directive immediately after it.

    https://github.com/Mitrichius/hugo-theme-anubis/blob/main/la...



    Which is now deprecated and no longer receiving updates! Haha, that’s hilarious in context of the post.

    It’s also maddeningly frustrating as someone who regularly has to update things on awful frontend projects no one else is willing to touch. Frontend work is cursed.



    Doesn't make it any less stupid or hypocritical. Dependencies you made a choice to use don't absolve you from responsibility.


    Actually, it doesn't matter at all.


    Great advice, but my case is different because our framework is REALLY hurting us.

    /s

    It's wild how easy it is to fall into this trap. IMO, if you're considering switching frameworks (especially for perf reasons), your time would be better served by getting parts of your app off framework completely (assuming there's truly no way to get the results you want in your current framework.)







    Join us for AI Startup School this June 16-17 in San Francisco!


    Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact



    Search:
    联系我们 contact @ memedata.com