Top Contributors

How do you debug your JavaScript?

Today I discovered this little util: https://github.com/krasimir/deb.js
It's really tiny but has a lot of potential.

Basically from this I played a bit with the Function.prototype to build a lame tracing module:
http://jsfiddle.net/AlexCode/39p6wmLa/

I'm sure there are more of these little tools around so, what do you use? Why? :)
Rank: Ace

Expert Comment

Rob2015-03-02 12:43 PMID: 147114
Chrome dev tools. it could be better but gets me by. I would like a tree view of all the available objects and their descendants.
I'll checkout that tool, but what do you use?
0
Rank: Genius

Author Comment

Alexandre Simões2015-03-02 01:51 PMID: 147119
Honestly I'm a console.log kind of guy :) and 99% of the time I use the Chrome dev tools.
I used to love firebug but I rarely open Firefox now...
IE dev tools are also getting much better which doesn't really mean that they're good :)

For debugging AngularJS stuff I occasionally use Batarang but still the old school console.log is my main choice.

That's mainly why this tool rang a bell in my head :)
With the amount of time I spend on JS, it's maybe about time I put some effort improving my debugging tool-belt.
0
Rank: Ace

Expert Comment

Rob2015-03-02 01:56 PMID: 147121
I have a similar approach. Firefox is just too slow and I only use other browsers to visibly test the site. Having said that, I've found Opera's dev tools really quite good.
I've also used the NetBeans connector for debugging JavaScript. There's also another plugin for knockoutjs but it's virtually useless
0
Rank: Prodigy

Expert Comment

COBOLdinosaur2015-03-02 02:28 PMID: 147124
I am also a console.log kind of guy... dinosaurs are like that tried and trusted stuff; but that tool looks like I could find some use for it.  I have almost completely eliminated the need for a lot of JS in stuff I develop, but with less use I make more errors, an so a new tools might help keep me on schedule.

Cd&
0
Rank: Ace

Expert Comment

Rob2015-03-02 11:37 PMID: 147159
I'd say I'm more if a console.dir kind of guy. I also love how $0 is the element you've selected in the DOM. What do you guys like about the dev tools that others may not know about?
0