✊🏿 Black Lives Matter. Please consider donating to Black Girls Code today.
⚡️ Concerned about the grid? Kyle Baranko teaches how to predicting peak loads using XGBoost. Register for the August webinar!

Execute a callback on component loading complete

I have a chart that takes a little while to update. I want to change the labels on a component in UI after this map rendering is complete.

I am able to indicate that the component isn’t ready with a spinner, but I am not able to do some actions post load of the component.

My current solution is to sleep for 5 seconds in the callback while the other graph updates (and changes the state of a store object).

I was able to achieve this with the following:

  1. Made my chart update from a multi-output callback where one output was a Storage component
  2. Used Input("data-store", "modified_timestamp") to check to see when this component was updated