Is there an example of clientside callbacks for Dash? I only found this, hidden in a closed github issue: https://github.com/plotly/Dash.jl/pull/30
I tried with this code, but it doesn’t work:
using Dash, DashHtmlComponents, DashCoreComponents
app = dash()
app.layout = html_div() do
dcc_input(id = "my-id", value="initial value", type = "text"),
html_div(id = "my-div", dcc_input(id = "disp", value=0))
end
callback!(
"""
function(input_value) {
return (
input_value
);
}
"""
, app,
Output("disp", "value"),
Input("my-id", "value")
)
run_server(app, "0.0.0.0", 8080)
EDIT: The code above works, it was just me not knowing Javascript.