有没有办法像 jQuery 那样通过选择器获取 Tabulator 对象?

Is there a way to fetch Tabulator object by selector like jQuery does?

我们可以创建对象,然后通过 table 变量引用它。像这样:

var table = new Tabulator("#example-table", { ... } );

但是有没有办法通过选择器获取 Tabulator 对象,比如 jQuery:

$( '#example-table' )     // Tabulator("#example-table")

这不会构造新的制表符,而只会构造 return 现有对象。

如果您想在 tabulator 4.0 及更高版本中使用 jQuery,您只需使用 jQuery Wrapper

$("#example-table").tabulator( ... )

可以找到使用它的完整指南Here