I think, as long the you have unique id for each card, react will take of render part.
Checkout this demo made for you.
Also, check this blog post too.
https://naveenda.medium.com/how-to-recursively-render-the-react-component-a821b3532894
If you don't get it, please let me know.