3 ms·
I agree completely. If you model is echoing long bits of HTML, or your views contain lots of SQL, that's not really MVC. Almost everything is just details. We g
by blowski 10y ago
I agree completely. If you model is echoing long bits of HTML, or your views contain lots of SQL, that's not really MVC. Almost everything is just details. We get excited about labelling them as 'ADR' or 'MVVM' but they are all just variations on a theme.
Perhaps the problem is that rules like 'no SQL in your views' is now so ingrained, a lot of juniors have never seen a monolothic mess of SQL mixed with HTML. So MVC is almost ubiquitous, and we then try breaking it down into different sub-categories.
- at-fates-hands 10y ago>> SQL mixed with HTML And now we have Javascript being mixed with HTML; which I never thought would happen.
- kensign 10y agoIt's funny how this anti-pattern like has become so widely accepted.
- simplify 10y agoJavaScript isn't a type of logic, it's a language. You wouldn't say JavaScript is the M in MVC, for example. If you have JS in HTML, and that JS code is strictly view logic, then your code still has a clear and useful separation of responsibilities.
- mikewhy 10y ago> now we have Javascript being mixed with HTML Now we have JavaScript mixed with an HTML-like syntax.