How to make child as props in For loop?
This is the way I come up.
But is this right?
I want to know most general pattern...
I know there is props.children. But I don't see any example in 'For' loop.
I want to use For's index.

3 Replies
that should be fine, but you should probably wrap p.child call in memo or fragment
Hmm why? it will be re-rendered always if not ?
it won't, because For callbacks only run once