Custom Render Widths

Found this workaround in HTML to make sure the page always stretch as max as it gets (2000px)

def _max_width_():
    max_width_str = f"max-width: 2000px;"
    st.markdown(
        f"""
    <style>
    .reportview-container .main .block-container{{
        {max_width_str}
    }}
    </style>    
    """,
        unsafe_allow_html=True,
    )

Just call this function in your app.py and you’ll be able to always start with wide-mode

13 Likes