且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

内容安全策略:无法在 Chrome 扩展程序中加载 Google API

更新时间:2023-12-05 19:47:58

只需使用 https 协议即可.您遇到的错误与内容安全政策有关.

Just make it use the https protocol instead. The error you're getting is regarding the Content Security Policy.

请参阅页面的放宽默认政策部分.它提到您只能将HTTPSchrome-extensionchrome-extension-resource 列入白名单.

See the Relaxing the default policy section of the page. It mentions that you can only whitelist HTTPS, chrome-extension, and chrome-extension-resource.