We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Seems like #476 is back in 0.4 and 0.4.1 on GitHub
library(shiny) shinyApp( ui = fluidPage(DT::dataTableOutput("tab")), server = function(input,output){ output$tab <- DT::renderDataTable({ DT::datatable( head(iris), options = list( columnDefs = list( list(className = "dt-center", targets = "_all") ) ) ) }) } )
The text was updated successfully, but these errors were encountered:
Confirmed. Thanks for reporting. Will investigate now...
Sorry, something went wrong.
It looks like the fix #476 misses the fact that besides of column indexes, there're 4 kinds of columnDefs.targets in total.
columnDefs.targets
0 or a positive integer - column index counting from the left A negative integer - column index counting from the right A string - class name will be matched on the TH for the column (without a leading .) The string "_all" - all columns (i.e. assign a default)
Works. Thank you!
For those who cannot use dev version of DT, list(className = "dt-head-center dt-center", targets = "_all") does the trick for me (DT 0.4)
list(className = "dt-head-center dt-center", targets = "_all")
Successfully merging a pull request may close this issue.
Seems like #476 is back in 0.4 and 0.4.1 on GitHub
The text was updated successfully, but these errors were encountered: