plotly dash callback reruns everything on any input
Dash 2.15, Python 3.11. I have a dashboard with 5 dropdowns and 3 graphs. Any single dropdown change triggers my one big callback that recomputes all 3 figures, which takes ~4 seconds because it re-queries pandas. I want only the affected graph to update. I know about dash.dependencies.Input vs State and multiple outputs, but it's getting messy. Is there a clean pattern for this - one callback per output, or use pattern-matching callbacks? Also is there a way to cache the intermediate results so switching back to a previous selection is instant?
4 replies