✊🏿 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!

How to Create collapsible sidebar

how to create a collapsible sidebar?

Not sure if you could get the “sliding” effect using pure Dash (you might have to use some JS or CSS), but you could use a dcc.Button to return the contents into a html.Div, e.g.


def do_show_hide(n_clicks):
    if n_clicks % 2:
        ... generate the contents ...
        return contents
         return ''
1 Like