Adust: header and Fillspace: true cannot be used both


I have a Datatable with column header title "This is a column with this content".

I set

id: "my_column",
header: "This is a column with this content",
adjust: 'header'

but my column has not adjusted based on header content which is "This is a column with this content".

If I remove the fillspace and leave only adjust header then it works but the fillspace is not working anymore.

Need to use fillspace and adjust header both for the columns


  • The fillspace and adjust properties provide totally different behavior for column sizing and weren't intended for use in one column simultaneously.

    So far I can suggest you use the fillspace in the initial config and apply adjustColumn method when it's necessary.

    But please note that dynamic changes for fillspace can be applied only through the column's config and after refreshing the entire structure:

    In case of adjusting to the column header, there's another option: as the fillspace reflects the minWidth of the column, you can set the minimal width based on the header using getTextSize method:

  • Thanks Listopad

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion