【解决方案】react native Android环境报错“Module was compiled with an incompatible version of Kotlin.”

引入sdk后编译报错如下:

/Users/xx/.gradle/caches/transforms-3/11e75dd86701e7f1a0f25e831b584232/transformed/jetified-react-native-0.70.4-debug-api.jar!/META-INF/ReactAndroid_debug.kotlin_module: Module was compiled with an incompatible version of Kotlin. The binary version of its metadata is 1.6.0, expected version is 1.1.15.

解决办法:

        在project build.gradle的buildScript ext 中增加

kotlinVersion = "1.6.0"

如图:

 

猜你喜欢

转载自blog.csdn.net/Leisurely94/article/details/127651636