gpt4 book ai didi

android - 在 react native 中发布 apk 时出现“react-native-gesture-handler”错误

转载 作者:行者123 更新时间:2023-11-29 02:22:33 27 4
gpt4 key购买 nike

我想发布我的项目并生成.apk 文件。我流过 native 文档,但在终端中使用 gradlew assembleRelease 命令后发生此错误。如何解决?

Configure project :app WARNING: Configuration 'compile' is obsolete and has been replaced with 'implementation' and 'api'. It will be removed at the end of 2018. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html

Task :react-native-gesture-handler:compileReleaseJavaWithJavac Note: C:\dev\react workSpace\SafarBeCom\node_modules\react-native-gesture-handler\android\src\main\java\com\swmansion\gesturehandler\react\RNGestureHandlerButtonViewManager.java uses or overrides a deprecated API. Note: Recompile with -Xlint:deprecation for details. Note: Some input files use unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details.

最佳答案

我经历过这个,你需要改变 app/build.gradle 文件,在 dependencies 部分,改变:

...
dependencies {
compile project(':react-native-gesture-handler')
}
...

到:

...
dependencies {
implementation project(':react-native-gesture-handler')
}
...

和:

您需要将项目的所有compile语句都改成实现。

关于android - 在 react native 中发布 apk 时出现“react-native-gesture-handler”错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54407321/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com