Last active
August 29, 2015 13:56
-
-
Save yajd/9283387 to your computer and use it in GitHub Desktop.
Alternative to cDump
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //from ff privelage scope | |
| Services.appShell.hiddenDOMWindow.console | |
| //from non-priv scope just do console.log or console.ingo | |
| //docs here: https://developer.mozilla.org/en-US/docs/Web/API/console.info | |
| //too use its functionality: | |
| //for typeof something do this: | |
| //http://mxr.mozilla.org/mozilla-release/source/toolkit/devtools/webconsole/utils.js#469 | |
| //to get webconsoleutils: | |
| //http://mxr.mozilla.org/mozilla-release/source/browser/devtools/shared/widgets/VariablesView.jsm#26 | |
| //http://mxr.mozilla.org/mozilla-release/source/browser/devtools/shared/widgets/VariablesView.jsm#35 | |
| XPCOMUtils.defineLazyModuleGetter(this, "devtools", "resource://gre/modules/devtools/Loader.jsm"); | |
| Object.defineProperty(this, "WebConsoleUtils", { | |
| get: function() { | |
| return devtools.require("devtools/toolkit/webconsole/utils").Utils; | |
| }, | |
| configurable: true, | |
| enumerable: true | |
| }); | |
| getObjectClassName |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
im real sure the populate function in VariableViewer.jsm is the function that itterates through all properties safely see here