Hi I have a reqirement in react. I need to copy the row of table in UI. means once user clicks on the highlighted icon in yellow in below image. the same row should be duplicated .
react
row of table in UI
clicks
yellow
row
duplicated
Could you guide me , how can I approach for the same?
so the below row should appear twice.
If you have the object that represents the row then just push the same into the array that consists of all this rows
array.push(clickedrow);
And let this array be a state so when you change it will rerender and you can see the updated list on UI.