Search code examples
ag-gridstreamlit

How to wrap and breaking textStreamlit AgGrid's Row?


I need to edit same dataframes when using Streamlit and found this very nice component AgGrid. However, I'm working with long text and I need to resize the rows to wrap the text in each cell. I need somtheing like st.table does:

enter image description here

How can I get the same type of wrapping AgGrid? Thanks


Solution

  • You can either add

    wrapText: true, 
    autoHeight: true
    

    to the defaultColdef property of the grid to do this for all columns, or to specific column definitions in the columnDefs property.