Issue
I went through the whole DataGrid documentations and couldn't figure out how we can display sting in multiple lines without ellispis inside a cell. This is the behaviour i am getting:
This is how I wanted:
Th string should extend to the second line if it is too big to be displayed in a single line. I have added width
, minWidth
and maxWidth
column properties to this column. These are the properties of the column:
field: item.name,
headerName: item.display,
hide: item.hidden
width: 200,
minWidth: 50,
maxWidth: 300
Please let me know if there is any way to achieve this.
Solution
Adding this property to the DataGrid solved the issue:
getRowHeight={() => 'auto'}
Answered By - Jayesh Babu
Answer Checked By - - David Goodson (ReactFix Volunteer)