Closed jatin-sandhuria closed 3 years ago
Hi I'll add one example to the README:
You can use the datatables.net cell classes like
dt-left
,dt-center
,dt-right
etc to set the cell alignment. Specify it for one table by using thecolumnDefs
argument ofshow
show(df, columnDefs=[{"className":"dt-center", "targets": "_all"}])
or globally by setting
opt.columnDefs
:
opt.columnDefs = [{"className":"dt-center", "targets": "_all"}]
df
How do I center align the header and the rows within the table ? I have tried many things but nothing seems to be working.