KeyboardVisibilityPlugin

KeyboardVisibilityPlugin

一切正常,但是升级软件包后,出现此错误。但是当我反转pubspec.lock时,我遇到了同样的错误...

    Projects/app/android/app/src/main/java/io/flutter/plugins/GeneratedPluginRegistrant.java:23:
error: a type with the same simple name is already defined by the single-type-import of KeyboardVisibilityPlugin
        import com.github.adee42.keyboardvisibility.KeyboardVisibilityPlugin;
        ^
        1 errorGradle task assembleDebug failed with exit code 1

最佳答案

解决方法如下:
1)搜索添加的插件中使用的keyboard_visibility插件。
2)删除或联系作者以解决此问题。
3)运行 flutter 干净。

这样我解决了这个问题。

09-13 11:50