Dash Aggrid conditional cell style don't respond correctly to callback

Hi Dash Community:

I am not sure if this is the expected behavior. However, what is what I experiences:

  • In the dash aggrid table, I code up the cell conditional background color ( very simple, no complicated logic ). I tried both approaches, code in python or code in java script.
    Dash.
    The cell condition is based on other cell values, which changes based on callback.

  • What is odd is:
    a) When the callback is fired, the cell condition doesn’t change immediately.
    b) When the callback is fired second time, the cell condition changes according to the value of first callback.

Was this expected? Thanks,

Hello @entropy_l,

This is expected. The cell only rerenders upon it being touched really. cellClassRules might work better for your scenario.

thank you so much. This works as expected now.
However, can you please clarify on what it means by “being touched really”? also, why it is designed this way? Thank you!

Touched meaning that cellValueChanged.

And this is how AG grid performs, not just our version. I am assuming because each time a cell adjusts the performance would degrade if you were constantly rerendering the whole thing.

1 Like

Thank you so much.

1 Like