onBlur Question #64
-
Hello, I have a use case - trying to figure out how to write updates on each edit. I'm maintaining the table data in state, and was hoping to pull out the updated row on edit based on the updated cell data. In my data each row is a record in the database, so updating by row is useful. Trying to capture the last edited cell with onBlur but it seems inconsistent in the cell data it gets. I was expecting after leaving the cell that onBlur would receive the last cell you were editing. Is this a bug in onBlur or am I confusing how it should work?
Is there a better way for me to identify which cell was last updated or a better way overall that I'm missing to implement my use case? Thanks. |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
I think we need some way to determine incremental updates on table cells (edits, pasting) with full access to row data. |
Beta Was this translation helpful? Give feedback.
-
@battebery sorry for the delay, what you are describing sounds like a bug. I'll test it out and create an issue if I can reproduce. Now regarding your broader problem, the way I would approach it is to keep in memory the original data and compare it to the updated data to see which rows have been updated. This sounds like an easier / less prone to bugs solution. @dmikoss can you be more specific, what would you need exactly? This is definitely an important topic, I'm trying to understand what people need and what would be the best way to achieve it. Thanks to both of you for your feedbacks ;) |
Beta Was this translation helpful? Give feedback.
-
This is now available in 3.4.0, please read the doc for |
Beta Was this translation helpful? Give feedback.
This is now available in 3.4.0, please read the doc for
onChange