I see some Angular dart samples specify the attribute binding using this form:
@NgComponent(
selector: 'foobar',
publishAs: 'foo',
map : const { "label" : "@label"}
)
While others annotate individual fields:
class FooBar {
@NgOneWayOneTime("label")
String label;
}
Is there a reason I would want to use one form vs. the other?
And a follow on question: Can I mix and match the two forms?
Let's say I have a base class:
MyBase {
@NgOneWay("label")
String label;
}
Can I inherit from that base class, and have Angular pick up the annotation?