Google Chrome Extension - Programmatically Open Popup

前端 未结 2 415
既然无缘
既然无缘 2020-12-06 13:56

When you make a Google Chrome Extension you can choose to have a \"Default_Popup\", is there any way to programmatically open the popup?

相关标签:
2条回答
  • 2020-12-06 14:30

    There is an API, chrome.browserAction.openPopup(function callback), that will hopefully be available soon. Please star this bug: https://code.google.com/p/chromium/issues/detail?id=436489

    0 讨论(0)
  • 2020-12-06 14:40

    There is no direct way to open the popup programmatically. However, if you're looking to open it based on a keyboard shortcut, you can use the commands API with the _execute_browser_action command (the API is currently available on the beta channel only).

    0 讨论(0)
提交回复
热议问题