views:

184

answers:

4

I find myself with a fairly complex JavaScript program and a bug that would be easier to solve given an ordered list of all the functions called.

I could generate a list manually by setting a break point, and stepping through the code line by line. I'm hoping there is something faster out there.

The Firebug profiler isn't much help as for some reason it is failing to generate any data, and only provides a summary of the functions called, not an ordered list.

Is there such a tool out there?

+3  A: 

try the Page Speed profiler. It is also a Firebug extension. It has an record mode called Page Speed Activity, where every js event/click/... is tracked and when you stop it, it shows all data in a long long list.

See http://code.google.com/intl/de-DE/speed/page-speed/docs/using.html#activities

powtac
A: 

If it's plain JavaScript (no browser stuff), you can use Rhino or a similar JS interpreter to run your code outside of the browser which should give you more options to debug it.

If you need a browser environment, try env.js.

Aaron Digulla
+1  A: 

I know you've already accepted an answer, but i'd recommend using Dynatrace Ajax it's potentially more powerful than pagespeed plus analyses Internet Explorer's javascript engine rather than Webkit's. I use Speed Tracer (advanced version of pagespeed for Chrome) and Dynatrace for IE. Couldn't recommend them both highly enough

Haroldo
A: 

Firebug has call stack functionality, which I've found to be handy. By "ordered list", do you mean "A called B, which called C", or "A was called, then returned. Then B was called."?

Zach Rattner