首页 > 解决方案 > angular stackblitz 项目中谷歌浏览器的警告和错误

问题描述

当我在 stackblitz 上加载与 Angular 项目相关的网页时,会收到错误和警告。这些错误发生在谷歌浏览器中,在 Firefox 中一切正常!
警告

The FetchEvent for "https://2.38.65.136:5001/getBrands" resulted in a network error response: an object that was not a Response was passed to respondWith()

注意:每个http请求都会发生这种情况

https 错误

Mixed Content: The page at 'https://angula-carsmarketplace.stackblitz.io/_sw_.js' was loaded over HTTPS, 
but requested an insecure resource 'http://andreadicioccio.byethost10.com/CarsImages/images/callCenterADS.jpg'. 
This request has been blocked; the content must be served over HTTPS.

注意:我知道这个错误,我理解它,但在 Firefox 中没有。所以我傻眼了。

错误拦截器消息

Http failure response for https://2.38.65.136:5001/getBrands

注意:每个http请求都会发生这种情况。请求永远不会到达服务器,我不知道为什么

Firefox 上的所有这些都不存在,一切正常!我想知道如何解决主要问题,即请求永远不会到达服务器的事实。由于一切都在 Firefox 上运行,我认为问题出在 chrome 设置上。
这是stackblitz 项目
谢谢

标签: angulargoogle-chromehttp-errorstackblitz

解决方案


推荐阅读