Ask HN: Angular/Knockout/Ember, logic in templates, and maintenance
For sure, they tackle a common problem and offer some really sleek solutions but the one thing that really bothers me is their use of HTML and templates:
<a href="#" {{ action "edit" target="parentView" }}>Edit</a>
Or something along those lines.What is really the difference between the previous line of code and this:
<a onclick="doSomething">Click me!</a>
Their use of HTML as something that it is not reminds me of ColdFusion and the really unreadable and unmaintainable HTML it required.So I really have to ask, what happened to separation of concerns and using HTML for markup, CSS for styling, and JavaScript for behavior?
Why is mixing markup and behavior so appealing? Or is it just something you live with in order to benefit from other aspects of these frameworks?
How maintainable is the code you produce using these frameworks?