Simultaneous debugging of Java and Javascript within IDE – Education Career Blog

Is it possibe to launch grails based java web project from within Eclipse or Netbeans IDE and setup breakpoints in both java and javascript sources and be able to debug both?

If so then how?

I understand debugging javascript is normally done using browser based debugger such as firebug for firefox but there are situations for large projects to be able to debug both javascript and java within IDE. In this scenario I think some sort of built-in mainstream browser or its extension is used within the IDE to support that specific browser.


The only time I’ve seen client-side and server-side code in the same IDE was years ago with MSIE, which used Visual Studio as its Javascript debugging tool. To be honest though, it wasn’t a particularly pleasant experience, and also it wasn’t integrated with the rest of the project.

Part of the problem with the idea of debugging Javascript in the IDE is that there’s no certainty of your JS code all being within your project. eg you could have loaded JQuery from Google’s code repository. So your IDE would have to load the Javascript code from the browser, not from the project. Also, some code may have been dynamically generated or even updated at runtime by Ajax calls, so the IDE would need to keep up-to-date with the browser.

When you start to think about it in those terms, you can see that it would be a very difficult task to debug the JS in the IDE. It makes a lot of sense to keep that functionality in the browser.






Aptana Studio provided dynamic javascript debugging (eclipse based, plugin version available)




Leave a Comment