基于https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/browserAction/setTitle应该可以使用类似的东西设置特定于窗口的browserAction Headers
browser.browserAction.setTitle({ title: 'foo', windowId: 3});
但是我得到了
Error: Type error for parameter details (Unexpected property "windowId") for browserAction.setTitle.
这是否意味着firefox中根本不支持这个?我在上面的文档页面上找不到任何相关信息 .
1 回答
我认为只有Firefox 62支持:https://bugzilla.mozilla.org/show_bug.cgi?id=1419893 . 注意到这一点的浏览器compat信息已更新(https://github.com/mdn/browser-compat-data/pull/2586),但尚未部署到MDN . 这可能会在今天发生 .