Hacker News new | ask | show | jobs
by throwawaysbdi 3380 days ago
Everything old sucks, but there's fixable and unfixable suckage.

IMO stuff like old PHP sites are fixable suckage. Usually minimal layers of abstraction and no crazy hooks affecting the vanilla behavior of the browser and HTTP. If they used libraries, it's usually for small stuff and they can be replaced without rewriting swaths of code. I can generally add new widgets to existing pages without fucking with what's there.

Webforms is a good example of unfixable suckage. The abstraction away from how the page and HTTP works is so thick that it's impossible to refactor slowly. Like angular, webforms takes over the page lifecycle. Client side code and MVC patterns just don't work nicely with it. I can't add anything to webforms pages outside of webforms because all these page reloads happen at unpredictable times and I can't stop them without breaking everything.

Every time I work on a webforms site with user complaints the most reasonable solution is to scrap it and start over. At least with other old shit that doesn't try to reinvent the wheel I can cordon off the really bad stuff and refactor

1 comments

I think that a lot of the 'unfixable suckage' comes to exist by people not wanting to rewrite boilerplate code to achieve a seemingly simple task, so they import someone else's boilerplate (angular) and use it to achieve their ends quickly. The fact that multiple boilerplates don't all work well or that one doesn't work in every case is hardly surprising.

I'd be curious if the time tradeoff in the "Rewrite the whole goddamn app" bucket is smaller than the one in the "Churn out boilerplate code and maintain it yourself" bucket.