Can I define a lightning:datatable column to default to “Wrap Text”?

Is it possible to have a column in the lightning:datatable component default to “Wrap Text”? Or is there a way to programmatically set this so I can do this in the init function of the parent component?


In lightning:datatable there is no attribute to set “text wrapping”.
So, you can only set wrapping by clicking from the drop-down menu on the column header.
Content is clipped by default if the number of characters is more than what the column width can hold.
As per latest release Notes, it is not possible.

Source : Link , Question Author : Carlo I , Answer Author : Ram Agarawal

Leave a Comment