google-chrome-devtools

Running code snippets from Google Chrome console command line, using (experimental) code snippets feature?

穿精又带淫゛_ 提交于 2019-12-02 18:59:06
Reference: Using the new code snippets feature in google chrome I am using the code snippets in google chrome, so say I have a snippet file. check_consistency.js Is there an api or a global object through which we can run the snippet directly from the command line, something like: window.runSnippet('check_consistency.js') or maybe call methods defined in the snippet directly. cwd Workflow Tip 1 I also want to see this functionality added. Meanwhile, perhaps try opening the Sources where (as you know) you can select a snippet and right click it to run it. You may or may not know that you can

How to add breakpoints in your inline javascript in chrome

我怕爱的太早我们不能终老 提交于 2019-12-02 18:44:19
I want to debug my javascript code and able to successfully place breakpoints at required places under sources tab. However, I have run into an issue where I want to debug my inline javascript code. Do we have any chrome debugging tool feature using which I can debug my inline javascript code. I am fine with using Firebug too for debugging purpose. PS: By inline javascript code, I mean JS code inside body tag and in the same file. fazzyx Another way can be using the dynamic script method. Chrome provides simple parser command which can tag dynamically loaded JS. <script type="text/javascript">

Chrome Dev Tools Issue With ES6 String Literals/Typescript

我怕爱的太早我们不能终老 提交于 2019-12-02 18:43:52
I am working on a project using Typescript and some of the ES6 features exposed by Typescript like ES6 String Literals e.g. `Something ${variable} Something else` . Whilst debugging a problem I dropped a breakpoint into my typescript file to step through it in the source panel, which usually works fine. But Chrome Dev Tools has an issue with ES6 String literals and doesn't seem to recognise the end of an ES6 String literal. Instead all code following the string literal is marked red (string highlighting in debugger) and blocked from variable inspection as chrome debugger seems to think it is

Chrome DOM breakpoint keeps enabling itself

那年仲夏 提交于 2019-12-02 18:43:22
Yes, in the console, I made the horrible mistake of setting a DOM breakpoint on an element that wasn't getting the content injected into it that I expected it to. Well, now whenever I load that page, the breakpoint triggers. I uncheck the box next to it. It comes back. I right click on it and click "Remove Breakpoint." It disappears from the list, and seems to work fine until the next hard refresh, then BAM breakpoint. I click the disable all breakpoints button. It once again works until the next refresh, then BAM breakpoint. Closed Chrome, reopened. Same. Closed all tabs individually and

Is it possible to filter options requests in chrome inspector?

别来无恙 提交于 2019-12-02 18:42:21
I'm building a web application which uses CORS to communicate with it's server. This means that every request is preceded by one with OPTIONS method. Is it possible to filter those out in inspector? It makes a lot of unnecessary clutter on network tab. Yes, you can use -method:OPTIONS in the filter of the Network panel to show all methods apart from ones with type OPTIONS . If you omit the preceeding - , it will only show methods of type OPTIONS . Example Before: After: You can read more about filtering in the Network panel here . 来源: https://stackoverflow.com/questions/39251291/is-it-possible

In the dev tools timeline, what are the empty green rectangles?

随声附和 提交于 2019-12-02 18:39:54
In the Chrome dev tools timeline, what is the difference between the filled, green rectangles (which represent paint operations) and the empty, green rectangles (which apparently also represent something about paint operations...)? Painting is really two tasks: draw calls and rasterization. Draw calls . This is a list of things you'd like to draw, and its derived from the CSS applied to your elements. Ultimately there is a list of draw calls not dissimilar to the Canvas element's: moveTo, lineTo, fillRect (though they have slightly different names in Skia, Chrome's painting backend, it's a

Debugging Javascript (Backbone and Marionette)

安稳与你 提交于 2019-12-02 18:23:54
Right now, while I am debugging backbone or marionette using the chrome dev tools, I end up setting break points and whatnot, but once the code pauses, its hard to tell what type of objects i'm working with because chrome labels everything a "child". (I think because that's the constructor function) Is there any easy way to either change this declaration or determine which type of model/collection i'm using. The amount craziness this causes in me wants to start doing something like this: MyModel = Backbone.Model.Extend({ // the $$$ puts it at the top of the inspector, the NAME is just for

Chrome developer tools: View Console and Sources views in separate views/vertically tiled?

北城余情 提交于 2019-12-02 18:17:50
Chrome developer tools: Is there a way to view the Console tab and the Sources tab in separate views? I often want to look at both of these simultaneously. Pressing Esc when on the Sources tab will let me see a small view of the Console at the bottom. But I'd like a larger view of the both at the same time. Is this possible? If not, is this something that a chrome extension might be able to do? Edit: Clarification - I know how to undock the dev tools window (that's my default setup). Just being greedy I guess and wondering if I can further split Sources and Console into separate undocked

Scrolling down in Chrome dev tools when paused in debugger

可紊 提交于 2019-12-02 17:51:12
Is there any way to scroll down on the page while Chrome is paused in debugger mode without unpausing? If your tools are docked, you can undock it to see a bit more. Another method: Go to the Elements tab. Right-click on any visible element (i.e. not hidden, display:none , etc.). Choose the "Scroll Into View" context menu entry. Chrome will scroll the page if necessary to get the element in the visible portion of the window. Taken from here . An easy workaround for the scrolling lock-up is to just jump to the console, and: window.scrollTo(0, 800) . (Replace 800 as needed) 来源: https:/

Is there any way to debug chrome in any IOS device

﹥>﹥吖頭↗ 提交于 2019-12-02 17:51:01
Is there any way to debug chrome browser on IOS device? If there is no way, how i can approach to bug in chrome on ios? Searched the web and didn't find sufficient answer. Old Answer (July 2016): You can't directly debug Chrome for iOS due to restrictions on the published WKWebView apps, but there are a few options already discussed in other SO threads: If you can reproduce the issue in Safari as well, then use Remote Debugging with Safari Web Inspector . This would be the easiest approach. WeInRe allows some simple debugging, using a simple client-server model. It's not fully featured, but it