网页中的iframe将消息传递给Chrome扩展程序(external_connectable)

在我的页面中,使用src空白创建了一个iframe。 然后将chrome.runtime.sendMessage(appId,option,callback)注入iframe。 但出现错误:chrome.runtime未定义。

由于content script有一个道具match_about_blank(请参见https://developer.chrome.com/extensions/content_scripts#match_about_blank) 如何在externally_connectable中取得成就? (官方文档:https://developer.chrome.com/apps/manifest/externally_connectable

dongjiahui 回答:网页中的iframe将消息传递给Chrome扩展程序(external_connectable)

暂时没有好的解决方案,如果你有好的解决方案,请发邮件至:iooj@foxmail.com
本文链接:https://www.f2er.com/3147460.html

大家都在问