Why is chrome.browserAction.onClicked undefined?

前端 未结 6 1166
情书的邮戳
情书的邮戳 2020-12-02 18:38

I\'m writing a Chrome extension that will redirect me to a URL when clicking on the browser action icon.

I\'m trying to use:

chrome.browserAction.onC         


        
6条回答
  •  清歌不尽
    2020-12-02 18:58

    Please notice that you can heave only one of app, browser_action, page_actions present in your manifest‎.json file.

    For example, to use the chrome.browserAction.setBadgeText you should have the browser_action field in your manifest‎.json.

提交回复
热议问题