如何解决成功构建的“:react-native-vector-icons”错误?

How to resolve ':react-native-vector-icons' error for a successful build?

我正在尝试构建我的 react-native 应用程序,但出现错误:

  • What went wrong: A problem occurred configuring project ':react-native-vector-icons'.

  • Could not resolve all files for configuration ':react-native-vector-icons:classpath'.

  • Could not find any matches for com.android.tools.build:gradle:2.3.+ as no versions of com.android.tools.build:gradle are available.

我尝试了以下命令:

我已尽我所能解决此问题,但无法消除此错误。有谁知道如何解决这个 react-native-vector-icons 构建失败错误?

您必须先卸载 react-native-vector-icons 插件。然后,重新安装它。只需输入:

$ npm uninstall react-native-vector-icons
$ npm install --save react-native-vector-icons