how to set width of datatable? code example
Example 1: datatables change width of columns
$('#example').dataTable( {
"autoWidth": false, // might need this
"columns": [
{ "width": "20%" },
null, // automatically calculates
null // remaining width
]
} );
Example 2: datatable column width
columnDefs: [
{ width: 200, targets: 0 }
],