I see that this StackOverflow question shows how to bind to a field that contains a function:
@NgComponent(
selector: 'mycomp',
publishAs: 'ctrl',
map: const {
'myfunc' :'&myfunc'
}
)
class MyComponent {
Function myfunc;
However, it is recommended to use annotations to declare what fields are bound, and how. I see @NgOneWay
(=>
) and others, but I don't see an annotation for &myfunc
.
What annotation should I use?