Image slider in Dash

I have just release version 0.0.47, which includes the BeforeAfter component. I have also added a small example to the docs,

import dash_html_components as html
from dash import Dash
from dash_extensions import BeforeAfter

app = Dash()
app.layout = html.Div([
    BeforeAfter(before="assets/lena_bw.png", after="assets/lena_color.png", width=512, height=512)
])

if __name__ == '__main__':
    app.run_server()

Peek 2021-03-21 10-20

2 Likes