Datatables + Bootstrap 5 + ColumnsDefs visible = false ISSUE

Datatables + Bootstrap 5 + ColumnsDefs visible = false ISSUE

JLDRJLDR Posts: 4Questions: 1Answers: 0

Hi there.
Something is missing here.

https://codepen.io/JLDR/pen/PojopYZ

If visible: true, you can resize window and responsive is working OK.
If you set visible: false, the middle column turns insivible (as expected), but responsiveness doesn't work anymore.

Is this a known issue or is something missing here?

Thanks in advance.

Replies

  • kthorngrenkthorngren Posts: 20,147Questions: 26Answers: 4,736

    There are a coupe things. First you should set style="width:100%" on the-tag table` tag as shown in this example. Doing this should fix the problem.. Second your example doesn't have any of the Datatables CSS files. Use the Download Builder to get the proper files for your Bootstrap 5 environment.

    Kevin

  • JLDRJLDR Posts: 4Questions: 1Answers: 0

    Thank you. The style attribute was missing and solve the problem.

Sign In or Register to comment.