I had learned that following piece of code is bad because it is obstrusive javascript and mixes presentation with logic:
<a href="" onclick="archive()">archive</a>
The best practice was to add some sort of identifier to the link element and then bound an event to it on a separate file. Something among those lines
$("#archive").click(function() {
//do stuff
});
See: Why is using onclick() in html a bad practice
How come now most Javascripts MVC frameworks like Backbone.js, Angular.js, etc now encourage pieces of code like this:
<a href="" ng-click="archive()">archive</a>
Taken from: http://angularjs.org/#todo-html
Why is this now ok?
<tag onclick="" ..
Also, since when you have begun looking at frameworks for good practices. As if Rails and CodeIgniter are not enough to deter you.