Determine if extension is enabled

Determine if extension is enabled

Wooly65Wooly65 Posts: 84Questions: 25Answers: 1

Link to test case: None

If there a way to determine if an extension has been enabled? I have some tables that have set the scroller: true and other datatables that are not using the scroller extension.

I have a general method for all datatables and need to check if the extension is enable or not. If this possible?

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 63,262Questions: 1Answers: 10,423 Site admin
    Answer ✓

    There isn't an API for it, but for scroller you could do:

    $('div.dts_label', table.table().container()).length === 1
    

    If that is true, then it is using Scroller.

    Allan

Sign In or Register to comment.