Dir

From FirebugWiki

(Difference between revisions)
Jump to: navigation, search
m (Added 'dirxml' to the links)
(Referred to the console.dir API and removed the duplicated contents)
Line 3: Line 3:
This looks identical to the view that inside the [[DOM Panel]] and also shares the display options with it. I.e. if you have unchecked ''Show DOM functions'' for example, they also won't be shown in the output of this command.
This looks identical to the view that inside the [[DOM Panel]] and also shares the display options with it. I.e. if you have unchecked ''Show DOM functions'' for example, they also won't be shown in the output of this command.
-
== Syntax ==
+
This command is a shortcut for the [[console.dir]] API.
-
<source lang="javascript">
+
-
dir(object)
+
-
</source>
+
-
 
+
-
== Parameters ==
+
-
=== object ===
+
-
Object to display the properties for. '''(required)'''
+
-
 
+
-
== Examples ==
+
-
<source lang="javascript">
+
-
dir(document.body)
+
-
</source>
+
-
 
+
-
Lists all properties of the <code>&lt;body&gt;</code> element.
+
-
 
+
-
<source lang="javascript">
+
-
dir(userDefinedProperty)
+
-
</source>
+
-
 
+
-
Lists all properties of the <code>userDefinedProperty</code> variable.
+
== See also ==
== See also ==
* [[dirxml]]
* [[dirxml]]
* [[Command Line API]]
* [[Command Line API]]

Revision as of 10:18, 18 November 2013

Prints an interactive listing of all properties of the object.

This looks identical to the view that inside the DOM Panel and also shares the display options with it. I.e. if you have unchecked Show DOM functions for example, they also won't be shown in the output of this command.

This command is a shortcut for the console.dir API.

See also

Personal tools