Javascript Object Tree Screener
Ever been in a situation when you’ve spent a week designing and debugging a Javascript or AJAX application only to find out it works in Firefox only? Most of the time the problem is due to differences between the methods and variables in built-in objects in browsers.
For example, the IFRAME object in Firefox exposes both contentDocument and contentWindow variables to access the document and the window objects encapsulated in the IFRAME, whereas in IE only the contentWindow is exposed, forcing you to access contentDocument via contentWindow.document.
There are scores of these differences that make the life of a Javascript developer difficult if not miserable.
There is a number of online tools on the Web that allow you to view Javascript objects in the browser, but all seem to be someone’s “learning Javascript” exercises, not very suitable for practical use.
So I sat down and came up with JOTS – Javascript Object Tree Screener. I am actively working on it, and have a few interesting and important features coming soon, but it is already a very useful tool.
Right now it works in Firefox, IE and Opera by using a javascript: bookmark that appends the tool to the target page, allowing you to view objects on a page of your choice. Safari strictly limits what you can put in a bookmark, so at this point you can only browse the objects contained in the tool itself, which is also fairly useful. You can also manually add a link to the tool to the target page.
