Speed up the loading of several datatables on a same view
Speed up the loading of several datatables on a same view
I use DataTables server side and I used 3 on a same view to a 3 partial view that I spent in this view. So all my javascript code is in this view and the architecture of my javascript looks like this one:
$(document).ready(function () {
$(function () {
var TableUser = $('#tableuser').DataTable({
//Code definition of columns
});
});
$(function () {
var TableGroup = $('#tableGroupre').DataTable({
//Code definition of columns
});
});
$(function () {
var TableClaim = $('#tableClaim').DataTable({
//Code definition of columns
});
});
});
the problem is that my page about 6s take a second before displaying the data to the first load which is quite normal for that it loads the information from 3 tables simultaneously. Would there a bearing means this problem to speed up loading and make asynchronous? Thank to you.
Answers
I use DataTables server side and I used 3 on a same view to a 3 partial view that I spent in this view. So all my javascript code is in this view and the architecture of my javascript looks like this one:
$(document).ready(function () {
$(function () { var TableUser = $('#tableuser').DataTable({ //Code definition of columns }); });
Plain text
1
2
3
4
5
6
7
8
9
10
11
$(function () {
var TableGroup = $('#tableGroupre').DataTable({
//Code definition of columns
});
});
$(function () {
var TableClaim = $('#tableClaim').DataTable({
//Code definition of columns
});
});
});
the problem is that my page about 6s take a second before displaying the data to the first load which is quite normal for that it loads the information from 3 tables simultaneously. Would there a bearing means this problem to speed up loading and make asynchronous? Thank to you