Closed
Description
It would be nice to have the ability to update multiple outputs at once by specifying a list of Outputs and returning a tuple with the same number of outputs like in
@app.callback(
[Output('label1', 'children'),
Output('label2', 'children'),
],
[Input('dropdown', 'value'),
])
def cb_test_multi(value):
# some very complex calculation to be triggered only once when 'dropdown' changes
...
# result of calculation need to be pushed partly on 'label1' and partly on 'label2'
return "Hello", value
This would allow simplifying otherwise complex flow to update multiple components based on one change.
Metadata
Metadata
Assignees
Labels
No labels