Requests made by Chrome Extensions - google-chrome

How do I see the requests made by the extensions running in Chrome in the background on a particular website?

You can monitor all HTTP traffic on you PC with Fiddler.

You can do that for extensions you are developing by looking at your extension / app background page (right click on the extension -> manage extensions -> inspect views under your extension).
Then open the debug panel (Ctrl+Shift+J) when looking at the background page of your extension (only debug extensions), you'll be able to see the network traffic for it.

Related

Can chrome extensions access other extensions' background pages?

I'm trying to build a Chrome extension A that makes use of network requests -- however, the network requests that are relevant to me are made through a separate extension B. Meaning, the network requests aren't viewable on the main 'inspect element' panel but only through inspecting extension B's background page in developer mode.
Is there any known way to access this information through extension A?
Thanks.

Chrome extension network activity not showing up

I'm trying to identify API calls that a chrome extension is doing, but I am not seeing those in the network tab of Chrome (inspect->network).
Is there a way to mask those out from there? Should I use a different tool to identify the network activity?
I guess you must be using DevTools for Chrome to debug you extension. In that case you can't see the network activities of your extension.
In order to debug you extension, you should use the DevTools for Extension:
Right click the extension icon, and you will see Inspect the popup, click that and select Network tab and you are done.
Like this(pay attention to the title of this):
For more infomation, you can see Debugging of the chrome-extension tutorial. Hope this helps.

“App banner support” in Chrome Devtools

Where is the "App banner support" setting for progressive web app installation in Chrome Canary 55?
Per this guide, I'd like to test whether the web app install banner is working correctly on my site.
The article shows its possible to test using the Chrome devtools mobile panel...
Here are his instructions:
If you don’t see the “Request app banner…” entry, try the following:
Update Chrome to the latest version
Enable the flag for “Devtools Experiments”
chrome flags enable-devtools-experiments and restart Chrome
Enable the option “App banner support” in Devtools -> Settings -> Experiments (If you don’t see it, press Shift six times there to get all experiments)
Enable the flag for “Add to shelf”
chrome://flags/#enable-add-to-shelf
So, I enable the flags, open the devtools, press shift x6 and I don't see anything in here about "App banner support".
The tutorial you mention is relatively dated, and the feature has since been moved and graduated from being a DevTools experiment.
Chrome 53/55 DevTools has an Application tab with an Add to homescreen link, which triggers the app-install banner if your app meets the criteria outlined below (errors logged to console):
Screenshot of install banner on Chrome 53/55, macOS Sierra:
Screenshot of install banner on Chrome 54, Android 6.0.1:
More recent (updated 6-Oct-2016) documentation on Web App Install Banners states:
Chrome automatically displays the banner when your app meets the following criteria:
Has a web app manifest file with:
a short_name (used on the home screen)
a name (used in the banner)
a 144x144 png icon (the icon declarations must include a mime type of image/png)
a start_url that loads
Has a service worker registered on your site.
Is served over HTTPS (a requirement for using service worker).
Is visited at least twice, with at least five minutes between visits.
Testing the app install banner
The app install banner is only shown after the user visits the page at least twice within five minutes. You can disable the visit-frequency check by enabling the Chrome flag #bypass-app-banner-engagement-checks. To test on desktop Chrome, you need to enable the Chrome flag #enable-add-to-shelf.
Then, as long as you have a manifest (configured correctly), are on HTTPS (or localhost) and have a service worker, you should see the install prompt.

How to start Chrome Hosted App in window?

So I know that 'Chrome Packaged App' will run in a window, I have tried to run the website I want in a <webiview> tag but it gets stuck at the beginning and I can't find a way to debug what's happenning inside that <webview> tag.
I now have tried to change the manifest to work as a 'Chrome Hosted App' but it keeps opening in a tab.
How do I start my app in a window, either by having it as a chrome hosted app?
Or by <webview> (if I find a way to debug it)?
As pointed here, a Chrome Hosted app can be open in a specific window if you enable this flag:
Enables the web app style frame for hosted apps
in chrome://flags.
Chrome's built-in developer tools can be used to debug packaged apps, extensions and webview as well as web pages (Right-click on any page element in webview and select Inspect Element).

How do you get WebGL Inspector to show up in Chrome?

In Chrome, I have the WebGL Inspector extension installed. The debug option does not show up in the address bar for the page I'm working on (that I'm using WebGL in). It shows up for other pages on the web. What are the requirements for getting it to give me the debug option?
I guess that you are trying to debug a local file (file://). If so, navigate to chrome://settings/extensions, expand the WebGL Inspector item and check "Allow access to file URLs".
Note: (outdated?) "readme.md" says:
You cannot inspect pages on file:// in WebKit (possible with security settings?)
You can also install a web server on your local PC to dispatch your page from a http:// url.