allow controllerAs to be used

add functionality for controllerAs