While developing goes forward and your web application gets larger and larger, the performance might slow down more and more. This results from the increasing amount of JavaScript code that must be executed by the browser.
This is the best moment to think about optimizing your code. Therefore, you have to profile many parts of your source code in order to find out which functions or code blocks are the largest performance eaters.
Firebug provides you with some useful functionalities that you can use to localize these performance eaters.
A simple way to find out how good the performance of a single code block or function is to wrap it into a
time
and
timeEnd
function. How we do this exactly will be discussed in the following section.