changxin commited on
Commit
37b967a
1 Parent(s): f9be81d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -0
app.py CHANGED
@@ -123,5 +123,12 @@ with demo:
123
  dt_output=gr.DataFrame(label="输出",max_rows=10,wrap=True)
124
  dt_button=gr.Button("分类汇总")
125
  dt_button.click(fx_dt, inputs=dt_input, outputs=dt_output,api_name='datatable')
 
 
 
 
 
 
 
126
  demo.launch()
127
 
 
123
  dt_output=gr.DataFrame(label="输出",max_rows=10,wrap=True)
124
  dt_button=gr.Button("分类汇总")
125
  dt_button.click(fx_dt, inputs=dt_input, outputs=dt_output,api_name='datatable')
126
+
127
+ with gr.TabItem("js"):
128
+ gr.Markdown("# js处理测试")
129
+ js_input=[gr.Number(),gr.Number(),gr.Number()]
130
+ js_output=gr.JSON(label="JS输出")
131
+ js_button=gr.Button("js处理")
132
+ dt_button.click(None, inputs=js_input, outputs=js_output,_js="(x) => [...x].reverse().join('')",api_name='js')
133
  demo.launch()
134