D
D
Delka2014-08-28 22:17:09
JavaScript
Delka, 2014-08-28 22:17:09

How to profile the performance of jQuery code?

I'm looking for slow sections of code in a jQuery script on a website. To do this, I use console.time/console.timeEnd because the Firebug/Chrome profilers show the lines in the jQuery library itself, and not in my script. How to do it better and more correctly?
There used to be a plugin from John Resig ejohn.org/blog/deep-profiling-jquery-apps that output exactly the slowest lines of your jQuery Js. But now, with modern versions of jQuery, it doesn't work.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
Sergey, 2014-08-28
Protko @Fesor

stackoverflow.com/questions/8384993/how-can-i-igno...

S
Sergey Romanov, 2014-08-29
@Serhioromano

I find the chrome inspector very good for this. It can show both CPU usage and the profiling tree itself. My experience with this tool says that although it was a little difficult to understand the idea and how it works at the beginning, then when you understand, everything is just class.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question