I have created a chrome extension which opens a new tab window,plays youtube videos and collects the network statistics.
What I currently do is to launch the chrome and then click the extension icon to run the extension. Now I want to automate the process of launching chrome and the extension simultaneously from command line.
Please guide me how I can open and run the extension on chrome from command line.
I have tried --load-and-launch-app and --load-extension.
You can move the logic of your extension in your background.js page. In this way when chrome starts, it will run your code in background.js without clicking extension icon.
For starting chrome use -
start chrome
Related
I am making a chrome extension that will allow recording screen but I want to do this in background script without even opening options page. How can I achieve this in chrome extension. I can see other extensions like loom are able to do so
I tried injecting script in tab but as soon as tab closes screen sharing disappears. I also tried to use getUserMedia or desktopapture in background.js but It didnot work
I want to debug a chrome extension downloaded from chrome store. is it possible and how.
I have readium chrome extension and it is not working properly. I want to know why.
Thanks
If the extension run front-end scripts: right click on the page, Inspect > Sources tab > Content scripts tab. Then you can select the Chrome extension that not work correctly and add a breakpoint for example.
If the extension run back-end scripts: Go to this url: chrome://extensions then scroll to your extension and click on background page button. A popup will be opened and you can go to the sources tab and debug the script.
I'm testing out Chrome Extension development and was testing how to do a page redirect through Chrome Extension.
Well it works, but now because of that I can't access the extension settings page.
How do I manually reload/disable the extension? Or do that from the Mac terminal?
My Chrome is pretty much unusable now thanks to my own code.
Thank you!
Tee
Your question seems to be "How can I reload my Chrome extension when it is not possible to do so from chrome://extensions because of my extension?"
A possible answer is:
Press Shift + Esc to open the task manager (or click on the hamburger menu -> More tools -> Task manager).
Select your extension.
Click on the "End process" button.
Now you can visit chrome://extensions and reload your extension in the usual way.
The previous only works if there is an extension process, not if your extension is purely a content script extension. If you still want to use the above method, you can force an extension process to become visible by opening chrome-extension://[extension id here]/manifest.json in a new tab.
I am able to launch Chrome browser with extension in the browser. But I am not able to interact with the extension.
When I launch Chrome browser manually, I go to chrome://extensions and configure command for that extension and set short cut like "Alt+H" to launch the extension from short cut and after hitting Alt+H the extension gets invoked.
But when I launch chrome browser with extension using watir webdriver, the configure command setting for that extension is not set. After I set that manually again to "Alt+H" and try to invoke the extension on the browser which is launched using watir-webdriver, I don't see extension getting invoked.
Please let me know how can I interact with the chrome extension using watir-webdriver.
I do not think watir can interact with the extensions. It can only interact with the page. But, I could be wrong. I had moderate success with Sikuli when I needed to do something like that.
I have developed a google chrome extension and I have a badge on the icon that displays a number.
When I start the browser the badge is not displayed. So I think I have to load the extension when chrome browser was started.
Is that possible?
Code in a background page is executed when a new browser window is created.