Angular refactor

Refactored code to use AngularJS.
just use `string`?