# based on https://solara.dev/documentation/components/input/slider
# but I added settng initial value to an integer instead of
# hardcoding `42` in two places.
import solara
initial_num = 42
int_value = solara.reactive(initial_num)
@solara.component
def Page():
solara.SliderInt("Some integer", value=int_value, min=-10, max=120)
solara.Markdown(f"**Int value**: {int_value.value}")
with solara.Row():
solara.Button("Reset", on_click=lambda: int_value.set(initial_num))