google-chrome-devtools

How to get console.log output in Terminal via Headless Chrome Runtime.evaluate

吃可爱长大的小学妹 提交于 2019-12-04 22:37:34
问题 I am following this issue post here: https://github.com/cyrus-and/chrome-remote-interface/issues/105 But I cannot seem to get console.log output in the Mac Terminal. It's probably inside the Chrome Devtools window which I don't see. So how do I get console.log output in Mac Terminal via Runtime.evaluate expression? My code below: const chromeLauncher = require('chrome-launcher'); const CDP = require('chrome-remote-interface'); const file = require('fs'); (async function() { async function

Google Chrome Dev tools can not show body content in Elements Tag

China☆狼群 提交于 2019-12-04 22:36:35
Anybody have the situation like this: Under Chrome Dev tools's Elements tag, body tag's content can not show. The only method is close the dev tool and reopen. It's a Chrome bug, it still happens in Canary, crbug.com/829884 . Refresh Devtools with Alt + R to fix if it happens. Edit: update - bug fixed Bug disappeared after I forced Chrome to look for new updates and let it update to the latest version. My version is now Version 67.0.3396.62 (Official Build) (64-Bit) 来源: https://stackoverflow.com/questions/50033710/google-chrome-dev-tools-can-not-show-body-content-in-elements-tag

Show only errors in Chrome development console

这一生的挚爱 提交于 2019-12-04 22:26:46
Is there a way to display only errors on the Chrome development console? Right now it displays about a million warnings and I have to search through them to find the errors. Thanks! In the latest version of Chrome console there is now a drop-down menu next to the Filter box, which is set to "Info" by default. This menu allows you to switch between only showing errors, warnings, info or verbose. Pictured here: madhu131313 You can hold the Control button (Command on Mac) to select more than one filter, such as 'Error' and 'Info' but not 'Warn'. Use the filter buttons in the bottom status bar (

Can I view Session State Value at client-side using Chrome DevTools?

为君一笑 提交于 2019-12-04 22:22:50
I was just curious if we can get/view Session variables values for a website using Chrome DevTools. If anyone knows, please share. No, you cannot view session state variables at client side. Session state is stored at server, and Client browser only knows SessionID which is stored in cookie or URL . ASP.NET Session State Overview Sessions are identified by a unique identifier that can be read by using the SessionID property. When session state is enabled for an ASP.NET application, each request for a page in the application is examined for a SessionID value sent from the browser. If no

Chrome 'paused in debugger' issue

断了今生、忘了曾经 提交于 2019-12-04 22:16:29
I don't know what I've switched on (by accident) but every time I have the Inspect Element area open and then try to click anything on the webpage not within the Inspect Element area (especially something jQuery related like a slideshow for example) it greys the page, shows a message saying 'Paused in debugger' and then opens a jQuery file within the Sources section of Inspect Element. Within the 'Call Stack' area, it shows a message saying 'Paused on a "click" Event Listener'. I don't remember switching this feature on but I'm keen for it to be switched off. I know this question has been

What does (idle) mean in Google Chrome DevTools Profiler?

别等时光非礼了梦想. 提交于 2019-12-04 22:16:22
Probably it's obvious but I can't find an answer.. What's the exact meaning of idle in this case? Is there really nothing going on? Or just no JavaScript getting parsed/executed? Rob W The meaning of "idle" is really obvious: "(idle)" means the time spent on doing nothing . Go to about:blank , and get a new CPU profile. The result is probably a value for (idle) close to 100% and a bit of (program) next question: Chrome debugger - What is "(program)" in the profiler? . 来源: https://stackoverflow.com/questions/20702940/what-does-idle-mean-in-google-chrome-devtools-profiler

How to 'add watch' in Chrome developer tools?

天涯浪子 提交于 2019-12-04 20:13:58
问题 I can't seem to find a way to add a watch expression for the selected JavaScript text in Chrome developer tools, the same way I would in Firebug with Ctrl+W. Is there really no way to do this in Chrome? I can't even right-click the selection as it unselects as soon as I do it, and there is no "Add watch" context menu item. Do I really have to type in every watch I want to add while debugging JS? 回答1: You can do it by clicking ' add to watch ' after right clicking You can also select the

JavaScript can not call content script JS function

依然范特西╮ 提交于 2019-12-04 19:24:58
I am developing chrome extension. I loaded JavaScript file successfully but the problem is external JavaScript (which I have loaded) can not call the function of content script files my code is as follows. $(document).ready(function() { $('.main_list').click(function() { $('.sub_list') .hide(); $(this) .parent() .children('.sub_list') .slideToggle("normal"); }); $('#click') .click(function() { $('.sub_list') .hide(); $(this) .parent() .parent() .children('.sub_list').slideToggle("normal"); }); $('#btnnewtask').click(function() { showdialog('http://localhost:51967/task.aspx'); }); $('

Is it possible to message the dev-tools panel from within inspectedWindow.eval?

僤鯓⒐⒋嵵緔 提交于 2019-12-04 19:10:27
I have been reading over the chrome extension message passing documentation , but I cannot seem to establish communication from within the inspected window. For example, chrome.devtools.inspectedWindow.eval('function() { . . . /* send message to dev-tools panel */ chrome.runtime.sendMessage({foo:"foo"});<-- Uncaught Error: Invalid arguments to connect. Why is the extensionId required within chrome.devtools.inspectedWindow.eval? This made me step back and ask the question. }') I have tried leveraging both background and content scripts to listen for these messages, but nothing seems to trigger.

Stopping content script in chrome extension

孤街醉人 提交于 2019-12-04 19:03:49
I have developed chrome extension , I have added , chrome.browserAction.onClicked.addListener which will start the script once clicked on , the script in turn will add a div at the bottom of the web page on the tab the browser action is clicked , All I have to do is , I need to add a close link which will stop the content script and close the div at the bottom , I have tried windows.close() , self.close() but nothing seems to work ,I would atleast want it to work in a way that 2nd time some one clicks on browser action, the script should stop. Here is my code, background.js chrome