0

切换到免费的 SSL WebHosting(000webhost),现在谷歌字体没有渲染,搜索并尝试了很多东西,重绘文本的 CSS 代码不起作用,JS 也不起作用,我尝试将字体 URL 与 https 链接:和没有协议 (//),什么都不会发生。

<link href="https://fonts.googleapis.com/css?family=News+Cycle&subset=latin,latin-ext" rel="stylesheet" type="text/css">

它仅在 Chrome 中发生,在 Opera 和 Firefox 中呈现正常。

奇怪的事实:当我用 F12 打开控制台并按 CTRL + F5 时,谷歌字体呈现正常,但只有当我打开控制台并重新加载时,当我正常进入站点时它不会呈现。如此疯狂。

这是控制台向我抛出的内容:

The FetchEvent for "https://fonts.gstatic.com/s/newscycle/v14/9Xe8dq6pQDsPyVH2D3tMQvk_vArhqVIZ0nv9q090hN8.woff2" resulted in a network error response: an "opaque" response was used for a request whose type is not no-cors

The FetchEvent for "same link" resulted in a network error response: an "opaque" response was used for a request whose type is not no-cors

The FetchEvent for "https://fonts.googleapis.com/css?family=News+Cycle&subset=latin,latin-ext" resulted in a network error response: an "opaque" response was used for a request whose type is not no-cors

The FetchEvent for "same link" resulted in a network error response: an "opaque" response was used for a request whose type is not no-cors
2undefined 

Failed to load resource: the server responded with a status of 404 ()

Failed to load resource: net::ERR_BLOCKED_BY_CLIENT
4

1 回答 1

0

是本地问题,输入:chrome://serviceworker-internals/

并删除与我的站点相关并工作的服务人员,如果在生产模式下发生,这将是可怕的。

于 2017-10-22T21:26:26.497 回答