react-native链接 - 重复调用会继续附加到配置文件

时间:2018-03-05 15:07:26

标签: react-native react-native-linking

React Native Link似乎不会解析先前对配置文件的更改,而是进行渐进式重复更改。

例如,android/app/build.gradle以:

开头
dependencies {
  compile project(':react-native-linear-gradient')
  compile project(':react-native-fcm')
  compile project(':react-native-cookie')
}

首次调用react-native link

dependencies {
  compile project(':react-native-vector-icons')
  compile project(':react-native-linear-gradient')
  compile project(':react-native-fcm')
  compile project(':react-native-cookie')
  compile project(':react-native-linear-gradient')
  compile project(':react-native-fcm')
  compile project(':react-native-cookie')
}

第二次调用后......

dependencies {
  compile project(':react-native-vector-icons')
  compile project(':react-native-linear-gradient')
  compile project(':react-native-fcm')
  compile project(':react-native-cookie')
  compile project(':react-native-vector-icons')
  compile project(':react-native-linear-gradient')
  compile project(':react-native-fcm')
  compile project(':react-native-cookie')
  compile project(':react-native-linear-gradient')
  compile project(':react-native-fcm')
  compile project(':react-native-cookie')
}

等等..

开始调查的好地方?

1 个答案:

答案 0 :(得分:1)

嘿,你的答案就在那里:react-native link causes duplicate imports in Android settings.gradle

目前正处于PR状态并正在接受测试。