Port to AngularJS from Backbone