I am trying to implement an alternative table widget for Panel as a Bokeh extension.
Currently I’m working on the flow:
- A user updates some data in the client table.
- Via javascript code I patch the ColumnDataSource on the Bokeh model
- Via python code I update the source DataFrame value on my Panel Python widget.
I can support 1+2. Now I’m looking at 3. For inspiration I’m looking at the panel.widgets.DataFrame
implementation. And from that it looks like what I can get is information that the data changed and then all the data. Then I have to find out which (single value) actually changed and update the data.
This seems inefficient. Is there a way to react to a patching event where I get information on the column/ key, index and new value only?
Additional Context
I guess one way is just on my model to add a _patched_data property that I can listen to changes of.