Jump to content

Does an Oject dump exist in JavaScript.


atrum

Recommended Posts

If you use Firebug, you can view a tree-menu style list of an object, plus it's children and parents, by adding a 'watch expression'.

 

Assuming you have it installed, open it on the page you wish to debug and select the 'Script' tab. In the left panel you'll see the JavaScript for that page, and within in the left margin of that panel, on the line containing a reference to the object, click in the left margin and a red dot should be appear. Run the code again, either by refreshing or calling the event that triggers the code, and in the right panel you should see the object.

 

It's not the most straight-forward tool to use, but it means you don't have to add debug functions or output to find the problem.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.