Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I inspect objects in Firefox Web Console using the keyboard?

When I enter the name of an object in the command line of the Web Console of Firefox, it shows up as [object Object].

I can then click on the object with the mouse to inspect it. Is there a way to do this using the keyboard, or to directly dump the object in expanded form?

like image 217
Tomas Avatar asked Jun 06 '26 18:06

Tomas


1 Answers

Sure, use console.dir(object).

I am surprised that it is not mentioned in https://developer.mozilla.org/docs/Tools/Web_Console.

Edited (2015-05-24):

Currently, there'a a entry for console.dir() on docs:

https://developer.mozilla.org/docs/Web/API/console/dir

like image 96
Mike Ratcliffe Avatar answered Jun 10 '26 18:06

Mike Ratcliffe