reactjs - axios 中的网络错误 react native for android
问题描述
嗨,我正在使用 axios 在 react native 中编写一个 get 调用。
当我直接调用部署在 aws 服务器中的以下 api 时,出现网络错误。
https://test.co.in/test/fetchAppFlags/mobilenumber
但是当我调用本地服务器中的 api 并由 ngrok 运行时,我得到了响应。
https://9929cda57b85.ngrok.io/test/fetchAppFlags/mobilenumber
在将我的 api 调用更改为 aws api 时进行上述调用后,我得到了响应。
https://test.co.in/test/fetchAppFlags/mobilenumber
在进行api调用或服务器配置端时,前端是否有任何问题。
谢谢你。
解决方案
推荐阅读
- arrays - Bash - 从变量中打印键和值
- python - R和jupyter notebook安装问题
- javascript - D3.js 用对象数据渲染条形图的问题
- javascript - Bootstrap popper.js 未能在资源的“完整性”属性中找到有效的摘要
- string - 拆分字符串重复 Tcl
- sql - 如何使用sql在父母中获取孩子的孩子值
- julia - Julia - 控制台的行为不同于 include("myfile.jl")
- graphql - 如何处理 GraphQL 模式中的空值
- python - PyCharm:无法安装 opencv-contrib-python
- javascript - 设置所选单选按钮的背景颜色