I've got a directive in an Angular3 Dart project:
@Directive(
selector: "[sample]",
inputs: const ["text1", "text2"]
)
class SampleDirective implements AfterContentInit {
... more code ...
@Input("text1") String text1 = "Some Text 1";
@Input("text2") String text2 = "Some Text 2";
}
Now when I'm using this directive:
<a-component *sample></a-component>
How do I pass in the text1 and text2 fields?
The cheatsheat mentions this example: <p *myUnless="myExpression">...</p>, but doesn't state what the myExpression part should look like.
These are the ones I've already tried, but none of them compiles.
<a-component *sample="text1:'TESTING' "></a-component>
<a-component *sample="text1='TESTING' "></a-component>
<a-component *sample="{text1:'TESTING'}"></a-component>
<a-component *sample="{text1='TESTING'}"></a-component>
Any idea how these expressions should be structured?