Columns Visibility plugin with jQuerUI?

Columns Visibility plugin with jQuerUI?

kerberonixkerberonix Posts: 7Questions: 5Answers: 0
edited December 2018 in Free community support

I can't get Columns Visibility to show up when using jQuery UI

I believe in older versions of datatables you could do something this like to get "ColVis" to show up with jQuery UI

    $(document).ready(function () {
        $("#example").dataTable({
        "bJQueryUI": true,
        "sDom": '<"H"Cfr>t<"F"ip>',
        "oColVis":
        {
           "bRestore": true,
            "buttonText": "Columns",
            "sAlign": "left",
            "sRestore": "View All"
        }
    });
    });

After reading the documentation it says that this has been moved to the buttons plugin. However the button doesn't show up when adding "jQueryUI: true' to the table options. How can I modify the code below to get the columns visibility button to show up when using jQuery UI?

Code taken from https://datatables.net/extensions/buttons/examples/column_visibility/simple.html

    $(document).ready(function () {
    $('#example').DataTable( {
        dom: 'Bfrtip',
        buttons: [
                'colvis'
        ]
    }); 
    });

Answers

This discussion has been closed.