Ionic2 + Angular2 - dynamic rate value with ion-icon star
<p>I'm trying to build a simple dynamic rate from 0 to 5 stars (and its middle values like x.5 [example 4.5] ) that receives a value from the javascript.</p>

<p>I looked for something with *ngFor but I'm not understanding how that works. Can someone explain / help me?</p>

<p>If it helps, for ionic, we have 3 type of stars available:</p>

<pre><code>&lt;ion-icon name="star"&gt;&lt;/ion-icon&gt;
&lt;ion-icon name="star-half"&gt;&lt;/ion-icon&gt;
&lt;ion-icon name="star-outline"&gt;&lt;/ion-icon&gt;
</code></pre>

<p>For example if I receive from server a value rate = 3.5, it renders:</p>

<pre><code>&lt;ion-icon name="star"&gt;&lt;/ion-icon&gt;
&lt;ion-icon name="star"&gt;&lt;/ion-icon&gt;
&lt;ion-icon name="star"&gt;&lt;/ion-icon&gt;
&lt;ion-icon name="star-half"&gt;&lt;/ion-icon&gt;
&lt;ion-icon name="star-outline"&gt;&lt;/ion-icon&gt;
</code></pre>

<p>I'm using javascript, no typescript.</p>

<p>Thank you so much :)</p>

<p>p.s. not sure if this title is the better, any suggestion is welcome :)</p>