79505498

Date: 2025-03-13 05:45:51
Score: 0.5
Natty:
Report link

Use a while to check if the button is pressed. The if statement wil evaluate to False, so it will just skip over it and continue. Your code should be like this:

import streamlit as st

btn = st.button("Click here")

while not btn:
    pass

# modal code here
"modal"
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: user5127