Use of Kendo UI Grid & Window Very high CPU Usage

388 views Asked by At

I have a simple app that is a set of Kendo UI windows containing datagrids. As soon as its running, its a huge strain on the system and visual grinds to a halt.

Its Chrome that is having the issues regardless of the project running or not, if those pages are loaded and just doing nothing other than sitting there in the browser, the computer is extremely slow

Wondering if anyone had similar issues, how to troubleshoot / resolve.

Some sample grid code

@{
    Layout = null;
}

@(Html.Kendo().Grid<DashboardViewModel.Payment>()
    .Name(Guid.NewGuid().ToString())
    .DataSource(dataSource => dataSource
        .Ajax()
        .Sort(sort => sort.Add("paymentId").Descending())
        .Read(read => read.Action("PaymentsJson", "Dashboard"))
    )
    .Columns(columns =>
    {
        columns.Bound(c => c.paymentId).Title("Id");
        columns.Bound(c => c.business).Title("Business");
        columns.Bound(c => c.createdAt).Title("Created").Width(110).DateFormat();
        columns.Bound(c => c.coupon).Title("Coupon");
        columns.Bound(c => c.quantity).Title("Qty").Width(80).Right();
        columns.Bound(c => c.price).Title("Price").Width(100).Right().CurrencyFormat();
        columns.Bound(c => c.discount).Title("Discount").Width(100).Right().CurrencyFormat();
        columns.Bound(c => c.total).Title("Total").Width(100).Right().CurrencyFormat();
    })
    .Filterable()
    .Pageable()
    .Sortable()
    .Groupable()
)
1

There are 1 answers

0
Dale Fraser On BEST ANSWER

This was actually nothing to do with Kendo at all. Thanks to Nicholas who made me question it and isolate.

<link rel="stylesheet" href="//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css">

This line of code in my template was the issue. Im not even sure how it got there but I dont use or need it. Removing that line fixed my issues. Perhaps that css was conflicting with something in kendo, not sure.