finished refactor for AngularJS
changed to min Angular