Created
August 1, 2022 11:35
-
-
Save erykml/79066af281143ff45c921d61009560c6 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from shiny import App, render, ui | |
app_ui = ui.page_fluid( | |
ui.h2("Hello Shiny!"), | |
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) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment