The console API contains few other methods that have practical use, especially when time is of essence.
If you want to take a look at all object's properties and methods, you can print it out directly into the console using console.dir()
method.
What's fantastic is that you can even output DOM elements.
You can track the amount of time between function calls with console.time()
and console.timeEnd()
. This can be helpful when optimizing code.
Source- Javascript Grammar
Top comments (0)