Login Register

Tools

Why does the Mozilla debugger (Venkman/Firebug/Aptana) report all errors in loader.js?

version:
1.0

This is a known bug in Mozilla.

There is a bug in the jsd (the debugging module of the Mozilla engine) dealing with code defined by an eval statement. If the code run by the eval is brought up in the debugger, it is reported as the line of code which executed the eval itself, plus the line offset within the eval. Since Dojo uses xhr + eval to load all code outside of the bootstrap, this is what you will typically see throughout your callstack when attempting to debug Dojo code in Mozilla.

What are HTTP monitors and debuggers?

HTTP monitors and debuggers are tools that monitor the HTTP traffic to/from the server; they are essential for ajax debugging.

For Firefox the answer is short, simple, and cannot be understated. http://getfirebug.com

What can I use to inspect the DOM tree?

When you install Firefox, you should select the option for DOM inspector. This tool shows you the DOM tree after the dojo widgets have been expanded. It's indespensible.

There are similar tools for IE. We recommend Microsoft's own Developer Toolbar.

Can I debug Dojo with Safari/Webkit?

version:
all
Webkit provides a debugger called Drosera and a set of tools that can help with Dojo debugging.

Can I debug with Venkman?

Yes. There's an optional flag available called "debugAtAllCosts" that pulls files in the "expensive" way, in order to provide exactly this. It requires that you include one more line in your usage. Here's how you might use it:

Why does IE report a syntax error when other browsers do not?

version:
all

Perhaps there is an extra comma at the end of a list. For example:

var request = dojo.io.bind({
                url: this.actionURL,
                method: 'get',
                content: {
                        id: this.rowId,
                        field: this.dbField,
                        value: this.checkbox.checked
                }// this comma shouldn't be here!
        });

Or:

var foo = [ 1 , 2, 3, ];

Or:

var obj = {
        apple: "delicious",
        brussel sprouts: "yucky",
};
Syndicate content