主题
安装
shell
pip install streamlit测试
app.py
shell
import streamlit as st
st.title("我的第一个 Streamlit 应用")
st.write("欢迎来到 Streamlit!")运行脚本
shell
streamlit run app.py
或者
python -m streamlit run app.py常用命令
更多:https://docs.streamlit.io/develop/api-reference/cli
查看当前版本
shell
streamlit versionStreamlit, version 1.42.2
查看配置
shell
streamlit config show指定端口
shell
streamlit run app.py --server.port 8888