Question from the Angular test

Why is the following snippet not validated? ```jsx <h1>Products Lists</h1> <ul> <li *ngFor="let p of products" *ngIf="p.stock > 0"> {{ p.name }} </li> </ul> ``` Answer: We cannot have ngFor and ngIf on the same element

Easy

Why is the following snippet not validated?

<h1>Products Lists</h1>

<ul>
   <li *ngFor="let p of products" *ngIf="p.stock > 0"> {{ p.name }} </li>
</ul>
Author: Emmanuel DemeyStatus: PublishedQuestion passed 2216 times
Edit
5
Community EvaluationsNo one has reviewed this question yet, be the first!