From FirebugWiki

(Difference between revisions)
Jump to: navigation, search
(Separate Console API page for console.timeEnd())
m (Added categories)
Line 23: Line 23:
* [[console.time]]
* [[console.time]]
* [[Console API]]
* [[Console API]]

Latest revision as of 00:12, 22 November 2013

Stops a timer created by a call to console.time() and writes the time elapsed since then.


[edit] Syntax


[edit] Parameters

[edit] name

Label used for the timer. required

[edit] Examples

for (var i=0; i<1000000; i++)
  var a = 1;

This measures the time how long one million assignments in a for loop take and prints the result to the console. The call to console.timeEnd("assignments") will stop the timer called "assignments" and print the elapsed time.

[edit] See also

Personal tools