views:

51

answers:

2

Could someone suggest some tool or how to configure firebug to display a list of defined variables in separate window.

I want to see variables, when any variable changes it property, at what line of code it have been changes and so on.

Because code becomes pretty big and following all needed variables is pretty hard now.

Have someone seen some tool with such capabilities?

Maybe there is some IDE, that have such functionality?

So basically i need to monitor JavaScript variables at separate window.

Thanks ^_=

A: 

check FireBug wiki

GustlyWind
Link-only answers aren't preferred on SO, because the linked resources can disappear. SO is meant to stand alone. Linking to a source is great, but also *quote* the relevant part that answers the question.
T.J. Crowder
+1  A: 
  1. Open the Firebug pane or window.

  2. Click on the "Script" tab.

  3. On the right-hand pane, click on the "Watch" tab.

  4. Click the "New watch expression...".

  5. Type or paste in your variable name.

  6. Enjoy!

Brock Adams
Yea great, but it seems i should update it manually :DIs it possible to watch it in realtime?Is it possible to trace line of code, where this variable was first defined or modified?It's all very useful and would save a lot of time for me.I guess it's better to write own debugging window and output everything there, but would be awesome if such functionality already exist in some debugging tool.Thanks again Adams. ^_=I know i'm asking too much, but why this isn't implemented yet? O_o
Beck
No and No. But you can set breakpoints where it is modified -- including conditional breakpoints. As for the rest, you could join the Firebug team. ;-) Or at least submit a feature request.
Brock Adams
PS. Some of what you want may be provided by the `console.trace()` function.
Brock Adams
Hmm, where to post request for new features? :)Thanks i'll look into trace.All could be easily fixed by adding possibility to log information to different(manually pointed), always on top, windows.For example:console.logTo(data,array(windowNumber/windowName,pin/unpin,grouped/ungrouped))
Beck
Hmm there are some functions like console.dir and console.group O_oHaven't seen them earlier.
Beck
Feature requests: http://code.google.com/p/fbug/issues/list
Brock Adams