shiny / app.py
Omar Sanseviero
Update app.py
ca21d8f
raw
history blame contribute delete
345 Bytes
from shiny import App, render, ui, run_app
app_ui = ui.page_fluid(
ui.input_slider("n", "N", 0, 100, 20),
ui.output_text_verbatim("txt"),
)
def server(input, output, session):
@output
@render.text
def txt():
return f"n*2 is {input.n() * 2}"
app = App(app_ui, server)
run_app(app, host="", port=7860, debug=True)