Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> “Locality of behaviour” is such a poorly defined rule.

And "separation of concerns" isn't?

What should be separated? Along what lines? How do we determine these lines? When does it make sense to pull some concerns out into another class/framework/markup/whatever? When does it make more sense to leave things stuck together?

The answer is: "It depends".

Not separating anything leads to spaghetti. Separating as much as possible, all the time, everywhere, leads to overly abstracted code that is easily as hard to maintain as spaghetti.



Yep. I've said this often but whatever:

JS, CSS, and HTML aren't concerns, they are technologies that have cross-cutting concerns.




Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

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

Search: