AngularJS implementation.