Putting everything together, here is an overview of the data flow in a Streamlit app:
Caching
Session state works well within a given session. But what if:
Widgets
Widgets (like st.button, st.selectbox and st.text_input) are at the heart of Streamlit apps. They are the interactive elements of Streamlit that pass information from your users into your Python code.