微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

错误 http://createerror@http//localhost:8081/index.bundle?platform=android&dev=true&minify=false:100129:26handle

如何解决错误 http://createerror@http//localhost:8081/index.bundle?platform=android&dev=true&minify=false:100129:26handle

我是本机反应的新手,但是我的机器上的虚拟模拟器很重,所以我决定在我自己的设备上模拟它,但是在尝试使用我的后端项目时,这个错误已经出现:

Possible Unhandled Promise Rejection (id: 0):
Error: Network Error
createError@http://localhost:8081/index.bundle?platform=android&dev=true&minify=false:100129:26
handleError@http://localhost:8081/index.bundle?platform=android&dev=true&minify=false:100033:27
dispatchEvent@http://localhost:8081/index.bundle?platform=android&dev=true&minify=false:32348:31
setReadyState@http://localhost:8081/index.bundle?platform=android&dev=true&minify=false:31432:33
__didCompleteResponse@http://localhost:8081/index.bundle?platform=android&dev=true&minify=false:31248:29
emit@http://localhost:8081/index.bundle?platform=android&dev=true&minify=false:3537:42
__callFunction@http://localhost:8081/index.bundle?platform=android&dev=true&minify=false:2765:36
http://localhost:8081/index.bundle?platform=android&dev=true&minify=false:2497:31
__guard@http://localhost:8081/index.bundle?platform=android&dev=true&minify=false:2719:15
callFunctionReturnFlushedQueue@http://localhost:8081/index.bundle?platform=android&dev=true&minify=false:2496:21
callFunctionReturnFlushedQueue@[native code]

我使用具有以下配置的 api.js


import axios from 'axios';

const api = axios.create({
  baseURL: 'xxx.xxx.x.xx',/* <---  My IP */
});

export default api;

不知道有没有其他人遇到过同样的错误

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。