ignore specific js files in chrome dev tools when debugging - google-chrome-devtools

Is it possible to ignore certain javascript files when debugging with breakpoints in Chrome Developer Tools? Let's say on this website http://todomvc.com/architecture-examples/angularjs/#/ I want to debug only todoCtrl.js and ignore all other ones like angular.js.

Yes, you can use JS Blackboxing to do this. The documentation for this feature will be going live soon, but for now you can read the WIP doc on how to do this here:
https://rawgit.com/jaredwilli/devtools-docs/blackboxing/docs/blackboxing.html

Related

Use Chrome Dev Tools as a library?

Is Chrome Dev Tools available only through Chrome extensions? Or is there a way we can use it, for instance, as a library from a JS standalone file?
Update
Chrome DevTools Frontend is now an NPM package that you can take advantage of. It is based from the new DevTools sub-repo in Blink. So you can easily pull in the DevTools assets and keep then up-dated without much work.
Original post
It depends on what you want exactly. You can dig in and rip out bits of the frontend to use. Like Betwixt by Konrad pulls the network panel design out and plugs it up to an OS interceptor. So you can use the network panel you know and love to debug any app on your desktop.
Now, can you easily do this kind of stuff. Even keeping it auto-updated? No, not really. It is fairly complicated and you need to be able to handle ripping the stuff out yourself. That being said, if you want a challenge then the code is open to everyone.
I'd say that the first sentence on the About website is pretty clear:
... built into Google Chrome.
So officially, by Google, it's only for Chrome. It's part of Chrome, not a standalone library. Issues linked to DevTools are part of Chromium, where people can contribute.

How to debug CoffeeScript using the generated source maps?

How to debug CoffeeScript using the generated source maps? Do I need to include the map file? What else do I need to do? I'm currently including both the compiled JS file and the map file, but my Firefox debugger doesn't seem to be doing anything special....
SourceMap debugging is only available on the next Firefox release, starting from Firefox 23.
You can download the developper preview (google for firefox 23). It should be available as RC during august according to Mozilla website.
In practice, you don't have to include the map file in your html file, you just have to reference your map in the javascript file. But the CoffeeScript compiler does it for you.
If you want to give a try at debugging CoffeeScript with SourceMap, you can try with Google Chrome dev Tools. Be sure to check Enable source maps in the dev tool configuration.
If you need further advices or examples on how to debugg CoffeeScript with Chrome, ask and I'll edit this post.

GWT: debug events capturing/bubbling

I wonder if there is a way to perform a step-by-step debugging of the compiled GWT code, in order to determine how some events are being fired.
The interest I have on this is that I'm using SmartGWT, and for some reason the click events on their components propagate to pop up windows that occupy the same position. However this only happens in Mobile Safari.
Even more interesting it only happens with smartGWT version of onClick and not with the plain GWT onClick.
Mostly a hack for now, but I suppose it'll work (you'll have to recompile your app though):
First, compile a recent GWT from trunk: https://developers.google.com/web-toolkit/makinggwtbetter#workingoncode
Then recompile your app with source maps enabled: http://code.google.com/p/google-web-toolkit/wiki/SourceMaps
Follow the steps in the comments of this wiki page to be able to use SourceMaps in Chrome, then re-deploy your app
Get Chrome on the Dev channel: http://www.chromium.org/getting-involved/dev-channel
Use http://www.iwebinspector.com/ to start Mobile Safari with remote debugging and then connect to it from your Chrome desktop: http://www.webkit.org/blog/1620/webkit-remote-debugging/
Finally, enable source maps in Chrome so you'll see your Java code in the Web Inspector!
See http://www.youtube.com/watch?v=-xJl22Kvgjg for a preview of the future of debugging with GWT, that will allow this kind of things in a much less hackish way in the near future.
I don't know if there is a nice way to debug compiled javascript GWT code, but why do you need it?
For described purpose it's better to use GWT development mode with debugging options. You can add the following parametres e-Xdebug -Xrunjdwp:transport=dt_socket,address={PORT},server=y,suspend=n to the development mode running command, it will give an opportunity to add breakpoints to the cliend side GWT/SmardGWT source code. Then for debugging you should connect to port specified in parametres from your java IDE.
Debugging GWT https://developers.google.com/web-toolkit/doc/latest/DevGuideCompilingAndDebugging

What languages I will need in order to write browser plugin that will work with GMAIL? [duplicate]

I want to write something similar to ActiveInbox.
In addition to original ActiveInbox, I need to add logic that will perform some actions on the emails that come.
What language(s) are programs like ActiveInbox written in?
Thank you
Activeinbox is a browser plugin, written in Javascript. It's easy to have a look inside: download the xpi (the Firefox version of the plugin). An xpi file is a zipfile, so open it with your zipfile manager of choice.
After that you should head over to Mozilla's developer site or a Chrome extension development tutorial to learn how to wite a Firefox/Chrome plugin.
Extensions can be written in pure Javascript on Chrome and Firefox.

Plugins + Extensions on Safari 5.0.1

My question is very simple: Is it possible to pack plugins into extensions for Safari? For instance, the exact NPAPI plugins which work on Google Chrome also work on Safari. However in Chrome I'm shipping the plugins as a part of an extension (a CRX package). This is needed because HTML and JavaScript is injected into a specific web page, and this code uses the plugins. I do not see an option in Extension Builder to specify plugin files and I haven't come across any proper documentation saying that plugins cannot be packed into extensions.
Any help will be greatly appreciated!
The first comment:
I don't think that is supported. A workaround could be a custom installer that installs both the plugin and the extension. – Georg Fritzsche
This is the only possible way to do it! FYI: Apple guys are against the idea of extensions accessing native code (ie, plugins). An obvious security loop-hole, but a necessity here! :)