[即将推出] 不要在小组件交互时重新运行
作者: jrieke创建于 2022年12月7日更新于 2026年9月28日
标签type:enhancementarea:widgetsarea:events
当用户与小组件进行交互时,Streamlit 总是重新运行整个脚本。虽然有办法绕过这个问题(表单、缓存等),但有时只需执行 `st.slider(..., rerun=False)` 这样的操作就非常有用了。有关此问题的请求,请参阅这个非常受欢迎的论坛帖子: https://discuss.streamlit.io/t/how-to-prevent-the-reloading-of-the-whole-page-when-i-let-the-user-to-perform-an-action/10800/7
内容来源: streamlit/streamlit