@mlink/datatables.net-scroller
Version:
Virtual scrolling plug-in for DataTables
31 lines (24 loc) • 786 B
text/xml
<dt-example table-type="scroller" table-class="display nowrap" order="5">
<css lib="datatables scroller" />
<js lib="jquery datatables scroller">
<![CDATA[
$(document).ready(function() {
$('#example').DataTable( {
ajax: "../data/2500.txt",
deferRender: true,
scrollY: 200,
scrollCollapse: true,
scroller: true,
initComplete: function () {
this.api().row( 1000 ).scrollTo();
}
} );
} );
]]>
</js>
<title lib="Scroller">API</title>
<info><![CDATA[
This example shows a trivial use of the API methods that Scroller adds to the DataTables API to scroll to a row once the table's data has been loaded. In this case `s-api row().scrollTo()` is used to jump to row index 1000.
]]></info>
</dt-example>