| ▲ | phyzix5761 2 days ago |
| "Best Practices" are pretty much dead in the AI era. Pretty soon no one is going to read any of the code AI produces and that's a scary thought. |
|
| ▲ | paulirish a day ago | parent | next [-] |
| IMO maintainability is the next frontier. If we just allow coding agents to accrete 1k-LOC solutions to problems, the codebases run quick away from our ability to maintain _some_ level of understanding. So I'll take a 1-line CSS solution over 60 lines of ResizeObserver/setTimeout business. But.. best practices for frontend isn't just the code.. it's ensuring quality UX, that keyboard navigability works, that layout doesn't shift on users. |
| |
| ▲ | noosphr a day ago | parent | next [-] | | You just regenerate the codebase, like how you do a recompile in C. Writing code is 2026 is worth as much as writing machine code was in 1996. | | |
| ▲ | runeb a day ago | parent | next [-] | | Relevant post "Regenerative Software" https://aicoding.leaflet.pub/3majnyfydzs2y/l-quote/10.0_0-10... | | |
| ▲ | noosphr a day ago | parent [-] | | I've not read text with such a high fraction of AI slop in a while. The heady days of a year ago. |
| |
| ▲ | soon_to_be_sb a day ago | parent | prev [-] | | Jesus! what a horrible idea! Are you in the business of selling tokens/electricity/gpus by any chance? Then good for you! But terrible for everyone else.... | | |
| ▲ | noosphr a day ago | parent [-] | | Yes, just like compilation was. | | |
| ▲ | soon_to_be_sb a day ago | parent [-] | | [flagged] | | |
| ▲ | jstanley 19 hours ago | parent [-] | | You want to recompile the entire binary even though you only changed a few lines of code and it's obvious which instructions need to change? How wasteful. | | |
| ▲ | soon_to_be_sb 17 hours ago | parent [-] | | Tell me how much the cost difference between recompiling and hand modifying the binary is...I ll wait. | | |
| ▲ | jstanley 17 hours ago | parent [-] | | Exactly. And in the future the cost difference between re-generating the source and hand-editing the source will likewise tend towards zero. | | |
| ▲ | soon_to_be_sb 16 hours ago | parent [-] | | That is an uncertain future, and the other guy was talking about 2026 Even then it might be risky due to losing undocumented/untested behaviors that has been added to the software. | | |
| ▲ | noosphr 15 hours ago | parent [-] | | I was talking about 1996 when I first started programming. You can tell because I said 1996. |
|
|
|
|
|
|
|
| |
| ▲ | aidos a day ago | parent | prev [-] | | Once again, thank you for all the work you and the team have done to improve the web and the experience for developers working with it. |
|
|
| ▲ | natorion 2 days ago | parent | prev | next [-] |
| Best practices are not dead if they result in better user experience. The focus is less on developer ergonomics though - true that. |
|
| ▲ | jefftk 19 hours ago | parent | prev | next [-] |
| This is mostly best practices for making websites work better, not for pretty HTML. |
|
| ▲ | sublinear a day ago | parent | prev | next [-] |
| The "modern web primitives" are also not even necessarily the "best practice". Browser-specific implementation gotchas tend to take about a decade to iron out for reasons that never have anything to do with code quality. Users are fickle and so are browser vendors, but that's a different topic. At the end of the day, there's just no escaping lots of manual testing across device and browser combinations if your goal is a polished result and not just something that "works". AI has done nothing to make this problem go away. If anything, it's made it worse because people don't even want to look at the code now! |
| |
| ▲ | zeroq a day ago | parent [-] | | Exactly. I've recently finished a browser game specifically targeting an old iPad Air 1 we had lying around the house. I had a working version after a weekend, but it took me a month to make it run smoothly on an over 10 years old mobile device. And the most recent browser available is almost 10 years old. Surprisingly I didn't missed too many "modern" JS features, as these were mostly functional programming oriented which doesn't play well with optimization anyways, and the ES6 was more than enough as a programming platform. Anyway, what I'm trying to say is that "the best practice" should be making your apps fast and accessible - as much as you can without having to sacrifice something you value - instead of chasing the latest and shiniest. Don't be a fashion driven developer. :) |
|
|
| ▲ | brlewis a day ago | parent | prev | next [-] |
| >Pretty soon no one is going to read any of the code AI produces and that's a scary thought. This is a misconception. Have your favorite agent summarize this video for you: https://www.youtube.com/live/zcLPGC-tvgk?si=YR68aHlFESD053bh |
| |
| ▲ | ozim a day ago | parent | next [-] | | Ugh it is Uncle Bob, not going to torture AI with this guy. But the fun part is that all of the proper software engineering practices are aimed at lowering amount of context a developer has to keep in his mind. So it directly applies to agent context. Less verbose code, less tokens to burn, separation of concerns, lower chance agent breaks something unrelated etc. | |
| ▲ | vik0 a day ago | parent | prev [-] | | >>Pretty soon no one is going to read any of the code AI produces and that's a scary thought. >This is a misconception. Have your favorite agent *summarize this video for you*: https://www.youtube.com/live/zcLPGC-tvgk?si=YR68aHlFESD053bh I can't tell if you're joking here | | |
| ▲ | brlewis a day ago | parent [-] | | I am not generally against using AI to reduce the amount of information you need to pay attention to, and I was not joking. There are multiple places in that interview with good articulation of the reasons why software fundamentals still matter, and what happens when you don't look at at least some of the AI-generated code. | | |
| ▲ | zahlman 20 hours ago | parent | next [-] | | > There are multiple places in that interview with good articulation of the reasons why software fundamentals still matter, and what happens when you don't look at at least some of the AI-generated code. Sure, I've seen the video before and remember many of the arguments. I don't agree with everything in Bob's approach, but I certainly agree with what he says about the value of looking at the code. But that doesn't at all mean that people will do it. | |
| ▲ | drawfloat a day ago | parent | prev [-] | | Why don't you just quote them then? Or quote whatever the LLM you used gave. | | |
| ▲ | brlewis a day ago | parent [-] | | Uncle Bob Martin and Matt Pocock discuss the risks of relying on AI agents without human oversight, emphasizing that unchecked code can lead to significant technical issues: - Accumulated Technical Debt: Uncle Bob notes that agents often leave behind "dog doo" (messy code) (05:13-05:18). If you don't clean it, the code becomes progressively worse as you build on it (11:06-11:10).
- Loss of Agent Coherence: When code quality degrades, agents struggle to maintain direction (11:13-11:16). They may enter a loop of inadvertently breaking existing features while attempting to fix new ones, eventually leading to them failing entirely or giving up (11:22-12:04).
- The "Trapped" Trajectory: Matt Pocock highlights the risk of a session's "trajectory" (23:18-23:45). Without intervention, an agent's initial messy approach or misaligned focus will continue throughout the entire session, reinforcing poor patterns instead of correcting them (23:35-24:00).
- Hidden Hallucinations: Even though agents are fast, they are still prone to hallucinations and misalignment (25:09-25:18). Relying on them blindly without deterministic tools or human spot checks risks incorporating silent, logic-breaking bugs into the architecture (09:08-09:19).
| | |
| ▲ | zahlman 20 hours ago | parent [-] | | Your comment got flagged and killed; I don't know whether automated systems attempt to detect AI-generated comments. I vouched for you because the content was explicitly solicited. |
|
|
|
|
|
|
| ▲ | stronglikedan 15 hours ago | parent | prev [-] |
| just tell the AI to use best practices when writing code /s |