Untitled

 avatar
user_9363972
javascript
18 days ago
1.2 kB
3
Indexable
Never
<Text style={{ height: 30 }}>
                  {item.rating === 5 ? (
                    <Image
                      source={require("../assets/images/five-stars.png")}
                      style={styles.ratingImage}
                    />
                  ) : item.rating === 4 ? (
                    <Image
                      source={require("../assets/images/four-stars.png")}
                      style={styles.ratingImage}
                    />
                  ) : item.rating === 3 ? (
                    <Image
                      source={require("../assets/images/three-stars.png")}
                      style={styles.ratingImage}
                    />
                  ) : item.rating === 2 ? (
                    <Image
                      source={require("../assets/images/two-stars.png")}
                      style={styles.ratingImage}
                    />
                  ) : (
                    <Image
                      source={require("../assets/images/star.png")}
                      style={styles.ratingImage}
                    />
                  )}
                </Text>
Leave a Comment