Huasushis

Results 6 comments of Huasushis

另外在这个新开的hexo中我也出现了FontAwesome无法正常显示的问题,可能是下载字体的时候请求头出问题了?

> Staticfile 目前本地 `hexo s` 使用 `localhost:4000` 预览时,会导致 CORS 无法加载资源文件,部署上博客后即可恢复正常。 但是我最开始是部署上到 vercel 上后也没有,换成 bootcdn 就能显示了。

下面是部署后的情况: ![image](https://github.com/EvanNotFound/hexo-theme-redefine/assets/87814384/21ea8a4a-fd5d-4903-a4f1-1ad80fc1487e) > 上图是使用 bootcdn 的情况 然后配置文件改为 staticfile,运行 `hexo clean & hexo g & hexo d` ![image](https://github.com/EvanNotFound/hexo-theme-redefine/assets/87814384/56907a55-36b5-417e-8ca6-a036faf0ae2f) 会发现副标题没有了,而且有字体未下载下来。 控制台报错: ![image](https://github.com/EvanNotFound/hexo-theme-redefine/assets/87814384/e960873b-7423-4b4f-a13f-07df23d6a0dd) 使用 chrome 或者 microsoft edge 浏览器访问网站甚至会出现一部分 js 无法从 cdn 下载的情况。

并且发现控制台报错指向的网址都是其他使用了 staticfile cdn 的最新版本的 redefine 的博客。 类似于: > Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://cdn.staticfile.org/hexo-theme-redefine/2.6.0/fonts/noto-sans-sc-v26-chinese-simplified-700.woff2. (Reason: CORS header ‘Access-Control-Allow-Origin’ does not match ‘https://mlou.xyz’)....