Codesire-Deng / Codesire-Deng.github.io

My Blog.
https://Codesire-Deng.github.io
2 stars 0 forks source link

Firefox无法访问 #2

Open wks opened 2 years ago

wks commented 2 years ago

使用Chromium可以访问,页面的各个区块会逐步显示。但在Firefox中打开时,页面一片空白,所有的动画效果都不见了。

控制台中可以看到一些报错信息,如:

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@6.1.1/css/all.min.css. (Reason: CORS request did not succeed). Status code: (null).

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://cdn.jsdelivr.net/npm/animate.css@3.1.1/animate.min.css. (Reason: CORS request did not succeed). Status code: (null).

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://cdn.jsdelivr.net/npm/animejs@3.2.1/lib/anime.min.js. (Reason: CORS request did not succeed). Status code: (null).

None of the “sha256” hashes in the integrity attribute match the content of the subresource. [codesire-deng.github.io](https://codesire-deng.github.io/)
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://cdn.jsdelivr.net/npm/@next-theme/pjax@0.5.0/pjax.min.js. (Reason: CORS request did not succeed). Status code: (null).

None of the “sha256” hashes in the integrity attribute match the content of the subresource. [codesire-deng.github.io](https://codesire-deng.github.io/)
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://cdn.jsdelivr.net/npm/hexo-generator-searchdb@1.4.0/dist/search.js. (Reason: CORS request did not succeed). Status code: (null).

None of the “sha256” hashes in the integrity attribute match the content of the subresource. [codesire-deng.github.io](https://codesire-deng.github.io/)
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://cdn.jsdelivr.net/npm/gitalk@1.7.2/dist/gitalk.css. (Reason: CORS request did not succeed). Status code: (null).

猜测Firefox的跨站访问策略稍微严格一些,可能需要在页面中声明一些东西才可以。不过我倒是觉得反正GitHub Pages不要钱,不如直接把依赖的js文件放进repo,也免得CDN在不同地区访问速度不一样。