如何处理错误-在codeandbox的React应用程序中“无法获取”

艾略什

我建立一个自定义事件日历Component为我的瑜伽Appcodesandbox实际上,我本来打算在它上执行此操作IDE,但是这种想法开始迅速发展,最终我使用了它。

我试图获得widthheight<div/>使用ref={(el) => this.props.testing((this.container = el)),然后试图访问的变暗componentDidMount(),非常喜欢这个方案。

突然,我开始遇到以下错误codesandbox

TypeError

Failed to fetch

This screen is visible only in development. It will not appear if the app crashes in production.
Open your browser’s developer console to further inspect this error.
This error overlay is powered by `react-error-overlay` used in `create-react-app`.

并在控制台上:

Failed to load resource: net::ERR_CERT_COMMON_NAME_INVALID

(index):1 Uncaught (in promise) TypeError: Failed to fetch

(index):1 Access to fetch at 'https://codesandbox.io/api/v1/sandboxes/wm1dl/cache' from origin
'https://wm1dl.codesandbox.io' has been blocked by CORS policy: Response to preflight request
doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the
requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors'
to fetch the resource with CORS disabled.

codesandbox.io/api/v1/sandboxes/wm1dl/cache:1 Failed to load resource: net::ERR_FAILED

我尝试检查我的网络和其他内容,但是我不知道如何规范化它。

我需要对此进行规范化,或者至少能够确保可以安全地将文件复制/提交到github,然后在IDE上使用它。

这是我的沙盒

巴伦·帕特罗

显然我们很多人都遇到了这个问题。这应该最终消失。

它不是一个阻止者。您可以关闭模​​式。就像那样

在此处输入图片说明

本文收集自互联网,转载请注明来源。

如有侵权,请联系[email protected] 删除。

编辑于
0

我来说两句

0条评论
登录后参与评论

相关文章

来自分类Dev

如何处理错误“无法解析符号..”

来自分类Dev

如何处理承诺中的错误?

来自分类Dev

如何处理淘汰订阅中的错误

来自分类Dev

如何处理Shapely中的舍入错误

来自分类Dev

如何处理GRequests中的错误?

来自分类Dev

如何处理Retrofit 2.0中的错误

来自分类Dev

如何处理R降价中的错误?

来自分类Dev

如何处理Angular组件中的错误

来自分类Dev

如何处理NestJS中的TypeORM错误?

来自分类Dev

如何处理python中的递归错误?

来自分类Dev

如何处理fetch()中的错误请求

来自分类Dev

如何处理python中的错误?

来自分类Dev

如何处理Haskell中的createProcess错误?

来自分类Dev

如何处理承诺中的错误?

来自分类Dev

如何处理execvp中的错误?

来自分类Dev

如何处理多个流中的错误?

来自分类Dev

如何处理mio中的错误?

来自分类Dev

如何处理python中的“回溯”错误?

来自分类Dev

如何处理spring集成中的错误

来自分类Dev

如何处理 Kafka Consumer 中的错误

来自分类Dev

如何处理 Django 中的错误

来自分类Dev

如何处理批处理文件中的sqlplus错误

来自分类Dev

再处理中如何处理403 HTTP错误?

来自分类Dev

如何处理Java Web应用程序中的异常和错误?

来自分类Dev

在扑朔迷离中创建语音识别应用程序时,如何处理此错误?

来自分类Dev

如何处理.NET Core应用程序中的自定义错误

来自分类Dev

如何处理Java Web应用程序中的异常和错误?

来自分类Dev

如何处理布线错误和通用导轨中的错误

来自分类Dev

如何处理套接字程序中的连接重置错误