I have the following state setup for a page using an abstract state and the controller as syntax:
# Details page route
.state \'title\',
url: \'/title\',
ab
Your controller needs to return the value of this
in order for the controllerAs feature to work properly. Since CoffeeScript implicitly returns the last line, you need to write:
return this
or if you are using the vm syntax and have written:
vm = this
you can write at the very end of the controller:
return vm