eliwill commited on
Commit
5cb129d
·
1 Parent(s): cb0cf12

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -3
app.py CHANGED
@@ -1,13 +1,15 @@
1
  import gradio as gr
2
  def update(name):
3
- return f"1) Welcome to Gradio, {name}!", f"2) Welcome to Gradio, {name}!"
4
 
5
  with gr.Blocks() as demo:
6
  gr.Markdown("Start typing below and then click **Run** to see the output.")
7
  with gr.Row():
8
  inp = gr.Textbox(placeholder="What is your name?")
9
- out = [gr.Textbox(), gr.Textbox()]
 
 
10
  btn = gr.Button("Run")
11
- btn.click(fn=update, inputs=inp, outputs=out)
12
 
13
  demo.launch()
 
1
  import gradio as gr
2
  def update(name):
3
+ return f"Welcome to Gradio, {name}!", "hello_world"
4
 
5
  with gr.Blocks() as demo:
6
  gr.Markdown("Start typing below and then click **Run** to see the output.")
7
  with gr.Row():
8
  inp = gr.Textbox(placeholder="What is your name?")
9
+ with gr.Column():
10
+ out1 = gr.Textbox()
11
+ out2 = gr.Textbox()
12
  btn = gr.Button("Run")
13
+ btn.click(fn=update, inputs=inp, outputs=[out1,out2])
14
 
15
  demo.launch()