Completed Vanilla JS, started based on AngularJS