小编Rom*_*gil的帖子

“侦听器通过返回 true 指示异步响应,但消息通道在收到响应之前关闭”,这是什么意思?

我正在开发一个 React 应用程序,并且使用了一些 npm 模块,其中一个模块是我必须自己构建的。(我的 NPM 包:\n https://www.npmjs.com/package/modale-react-rm)。

\n

这是一个简单的模式,用 来打开和关闭useState()

\n

导入包后,我的控制台中出现错误,几秒钟后突然出现错误,而没有执行任何操作。

\n
\nUncaught (in promise)                                                                  localhost/:1\n\n    >{message: \'A listener indicated an asynchronous response by r\xe2\x80\xa6age channel closed before a response was received\'}\n         message: "A listener indicated an asynchronous response by returning true, but the message channel closed before a response was received"\n        >[[Prototype]]: Object\n             >constructor: \xc6\x92 ()\n             >[[Prototype]]: Object\n\n       /* sometimes there are specific elements in addition but I could not check when they appear …
Run Code Online (Sandbox Code Playgroud)

javascript npm reactjs

193
推荐指数
5
解决办法
40万
查看次数

标签 统计

javascript ×1

npm ×1

reactjs ×1