一、所遇问题

在搭建react native环境中,遇到执行react native  run-android命令出现如下问题

1  Could not resolve all dependencies for configuration ':classpath'.
2    > Could not resolve com.github.dcendents:android-maven-gradle-plugin:3.1.4
3      Required by:
4          project :
5       > Could not resolve com.github.dcendents:android-maven-gradle-plugin:3.1.4
6          > Could not get resource 'https://jcenter.bintray.com/com/github/dcendents/android-maven-gradle-plugin/1.3/android-maven-gradle-plugin-1.3.pom'.
7             > Could not GET 'https://jcenter.bintray.com/com/github/dcendents/android-maven-gradle-plugin/1.3/android-maven-gradle-plugin-1.3.pom'.
8                > Connect to 127.0.0.1:80 [/127.0.0.1] failed: Connection refused: connect

报错原因是:是因为gradle配置文件启动了代理,导致无法访问。把gradle.properties文件里代理的配置语句注释掉即可(即下面第二张图红框的内容)

搭建react native所遇到的坑

搭建react native所遇到的坑

 

相关文章:

  • 2022-12-23
  • 2021-06-06
  • 2021-08-06
  • 2021-04-12
  • 2021-05-02
  • 2021-11-30
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-07-01
  • 2021-11-09
  • 2022-01-20
  • 2022-12-23
  • 2021-12-22
相关资源
相似解决方案