docs: Add asterisk info in template syntax guide (#36176)

Add helpful alert for asterisk syntax in the `ngFor` section of template syntax guide

PR Close #36176
This commit is contained in:
Aristeidis Bampakos 2020-03-21 18:58:42 +02:00 committed by Misko Hevery
parent c3a85ceabc
commit e81ad3a1bc
1 changed files with 8 additions and 0 deletions

View File

@ -1600,6 +1600,14 @@ The following example shows `NgFor` applied to a simple `<div>`. (Don't forget t
<code-example path="built-in-directives/src/app/app.component.html" region="NgFor-1" header="src/app/app.component.html"></code-example>
<div class="alert is-helpful">
Don't forget the asterisk (`*`) in front of `ngFor`. For more information
on the asterisk, see the [asterisk (*) prefix](guide/structural-directives#the-asterisk--prefix) section of
[Structural Directives](guide/structural-directives).
</div>
You can also apply an `NgFor` to a component element, as in the following example.
<code-example path="built-in-directives/src/app/app.component.html" region="NgFor-2" header="src/app/app.component.html"></code-example>