How to display more than one list element with different values from multiple arrays? #750
-
Hi there, we want to show three list items inside of an unordered list and receive the data out of an array, for each list item. We deconstructed it like that:
In our code, we want to get the dates and the temperatures and we wrote it like that:
We tried it with mapping, but we want three list elements and not just one and we don't want to write so many maps. We are asking ourself if this is the best practice or is there another, more elegant solution? Here is the PR Looking forward to your feedback! Thanks in advance ✌️ |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Hello there, we found a solution like this, we would be glad if you could give us some feedback for that one:
|
Beta Was this translation helpful? Give feedback.
Hi Jess,
Thank you for your feedback, it helped us and we can delete some code lines which is always nice ✌️
We adjusted your code a little bit, because we don't need the slice, so the code looks like this
Why don't we need the slice? Because we can adjust the number …