2

I have a react-table being loaded with 1 blank editable row. I have a button where I'd like to add a new blank editable row to the table.

I can add the new blank row to the data, but the Table is not updating. The table only updates with the correct amount of rows after I've changed a value from an existing textbox.

Here's the codesandbox link:

https://codesandbox.io/s/wandering-forest-u7r7lx?file=/src/App.js

Sonny
  • 29
  • 5
  • 1
    I updated the sandbox with what I think is a fix. I added the updateMyData function call to my addNewRow function and that seems to refresh the table. I'm not sure why this is the case though. I'm still new to react. – Sonny Feb 28 '22 at 22:44

0 Answers0