當前位置: 首頁>>編程示例 >>用法及示例精選 >>正文


Python Streamlit st.spinner用法及代碼示例

在執行代碼塊時臨時顯示一條消息。

函數簽名

st.spinner(text="In progress...")
參數說明

text (str)

執行該塊時顯示的消息

示例

with st.spinner('Wait for it...'):
    time.sleep(5)
st.success('Done!')

相關用法


注:本文由純淨天空篩選整理自streamlit.io大神的英文原創作品 st.spinner。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。