Javascript 拒绝加载样式表'';因为它违反了以下内容安全策略

Javascript 拒绝加载样式表'';因为它违反了以下内容安全策略,javascript,css,meteor,browser,cross-browser,Javascript,Css,Meteor,Browser,Cross Browser,我正在开发一个实现浏览器策略的应用程序。根据这里的文档[https://themeteorchef.com/tutorials/using-the-browser-policy-package][1] ,我添加了允许某些域的选项,如Google字体、W3学校css 令我惊讶的是,所有的选项集都会导致更大的错误。我不知道该怎么办 代码如下: Meteor.startup( () => { BrowserPolicy.content.allowEval(); BrowserPo

我正在开发一个实现浏览器策略的应用程序。根据这里的文档[https://themeteorchef.com/tutorials/using-the-browser-policy-package][1] ,我添加了允许某些域的选项,如Google字体、W3学校css

令我惊讶的是,所有的选项集都会导致更大的错误。我不知道该怎么办

代码如下:

Meteor.startup( () => {
    BrowserPolicy.content.allowEval();
    BrowserPolicy.content.allowInlineStyles();
    BrowserPolicy.content.allowInlineScripts();
    BrowserPolicy.content.allowStyleOrigin('w3schools.com');
    BrowserPolicy.content.allowOriginForAll( 'fonts.googleapis.com' );
});
这是错误消息:

    Refused to load the stylesheet 'https://www.w3schools.com/w3css/4/w3.css' because it violates the following Content Security Policy directive: "style-src 'self' 'unsafe-inline' http://w3schools.com https://w3schools.com http://fonts.googleapis.com https://fonts.googleapis.com".
    
    home:10 Refused to load the stylesheet 'https://www.w3schools.com/lib/w3-theme-blue-grey.css' because it violates the following Content Security Policy directive: "style-src 'self' 'unsafe-inline' http://w3schools.com https://w3schools.com http://fonts.googleapis.com https://fonts.googleapis.com".
    
    home:157 Refused to load the stylesheet 'https://cdnjs.cloudflare.com/ajax/libs/bootstrap-multiselect/0.9.13/css/bootstrap-multiselect.css' because it violates the following Content Security Policy directive: "style-src 'self' 'unsafe-inline' http://w3schools.com https://w3schools.com http://fonts.googleapis.com https://fonts.googleapis.com".
    
    home:181 Refused to load the script 'http://www.google-analytics.com/ga.js' because it violates the following Content Security Policy directive: "script-src 'self' 'unsafe-inline' 'unsafe-eval' http://fonts.googleapis.com https://fonts.googleapis.com".
    
    (anonymous) @ home:181
    (anonymous) @ home:182
    home:204 Refused to load the stylesheet 'https://www.w3schools.com/w3css/4/w3.css' because it violates the following Content Security Policy directive: "style-src 'self' 'unsafe-inline' http://w3schools.com https://w3schools.com http://fonts.googleapis.com https://fonts.googleapis.com".
    
    home:205 Refused to load the stylesheet 'https://www.w3schools.com/lib/w3-theme-blue-grey.css' because it violates the following Content Security Policy directive: "style-src 'self' 'unsafe-inline' http://w3schools.com https://w3schools.com http://fonts.googleapis.com https://fonts.googleapis.com".
    
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGKhisFFF-0ifc-Simo8uwJs.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGNJvocFWY_5VFjYFbAOOIik.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGLGN1mc631ObjHzqJB_dFFA.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGI3P6ux3HwbL10a8ofNXGLA.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGD_j0nMiB9fPhg_k1wdK2h0.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGDRVvBvQIc1z78c__uoBcyI.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGOode0-EuMkY--TSyExeINg.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGMKLL5CtqrIC1MmqTPxryYA.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGLttwilxDzpVRPUtYE2He8E.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGMqNlGGfRq7bLR7KpoutytU.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGDN0peKJ_L8b-UGHSLXfhhU.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGLpVETArfVi9McBbsQ4atuQ.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGEfh7q1GW6w7vv_rRnRqMrY.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/sourcesanspro/v10/toadOcfmlt9b38dHJxOBGHZhYM0_6AejPZE-OqA592o.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'data:application/font-woff2;charset=utf-8;base64,d09GMgABAAAAAFQ0ABEAAAAAvI…rnptIwTkWGE9bL/2LchXN+inLcDLxE7fAT7xFB4hM6CbaEib4mSsIr4jjCV4pIX7nsL37WAw==' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAAGoUABEAAAAAvJA…yA/lwxAAf/NQSDtWIEhivFGIyWigkYLxSHYJIrpuCQK47ANGwpKOEfDz5cKAAAAAABViuSJAAA' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'data:application/font-woff2;charset=utf-8;base64,d09GMgABAAAAAFQwABEAAAAAu+…TMo+yMPA6lZ2QRKDkj9UHxGYkaRWfE00yl+QXhIKt7l1TvpYyaq9tpVfMDKs1aPYiU6adsBAAA' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAAGsMABEAAAAAu+g…HK0icGuaVH9BeWLtFLLadE92YZ9x/IQ8dskvRJDOk/SWmS7H40mOk31btNXAAAAAFWK5GuAAA=' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/opensans/v14/K88pR3goAWT7BTt32Z01mxJtnKITppOI_IvcXXDNrsc.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/opensans/v14/RjgO7rYTmqiVp7vzi-Q5URJtnKITppOI_IvcXXDNrsc.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/opensans/v14/LWCjsQkB6EMdfHrEVqA1KRJtnKITppOI_IvcXXDNrsc.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/opensans/v14/xozscpT2726on7jbcb_pAhJtnKITppOI_IvcXXDNrsc.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/opensans/v14/59ZRklaO5bWGqF5A9baEERJtnKITppOI_IvcXXDNrsc.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/opensans/v14/u-WUoqrET9fUeobQW7jkRRJtnKITppOI_IvcXXDNrsc.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/opensans/v14/cJZKeOuBrn4kERxqtaUH3VtXRa8TVwTICgirnJhmVJw.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    meteorInstall.node_modules.meteor.es5-shim.client.js @ es5-shim.js?hash=adc3c62…:33
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130
    (anonymous) @ es5-shim.js?hash=adc3c62…:2783
    (anonymous) @ es5-shim.js?hash=adc3c62…:2789
    es5-shim.js?hash=adc3c62…:1143 Refused to load the font 'https://fonts.gstatic.com/s/opensans/v14/K88pR3goAWT7BTt32Z01mxJtnKITppOI_IvcXXDNrsc.woff2' because it violates the following Content Security Policy directive: "default-src 'self' http://fonts.googleapis.com https://fonts.googleapis.com". Note that 'font-src' was not explicitly set, so 'default-src' is used as a fallback.
    
    (anonymous) @ es5-shim.js?hash=adc3c62…:1143
    (anonymous) @ es5-shim.js?hash=adc3c62…:1151
    $Array @ es5-shim.js?hash=adc3c62…:164
    es5-shim.js @ es5-shim.js?hash=adc3c62…:169
    fileEvaluate @ modules-runtime.js?hash=2b888cb…:207
    require @ modules-runtime.js?hash=2b888cb…:130

您的代码看起来不错。我不太确定,但让我们尝试将
https
放在您的链接中:

//...
BrowserPolicy.content.allowStyleOrigin('https://w3schools.com');
BrowserPolicy.content.allowOriginForAll('https://fonts.googleapis.com');
//...

谢谢你,康。