【问题标题】:Map not work while after add firebase to the project将firebase添加到项目后地图不起作用
【发布时间】:2020-12-16 03:06:40
【问题描述】:

这是flutter抛出的错误 未处理的异常:PlatformException(错误,java.lang.IllegalStateException:尝试创建未注册类型的平台视图:plugins.flutter.io/google_maps

 configurations {
    implementation.exclude module:'protobuf-lite'
}
dependencies {
    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
    implementation 'com.google.firebase:firebase-messaging:20.2.4'
    testImplementation 'junit:junit:4.12'
    implementation 'com.android.support:multidex:1.0.3'
    androidTestImplementation 'androidx.test:runner:1.2.0'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
    implementation 'com.google.firebase:firebase-inappmessaging-display:19.1.0'
    implementation 'com.google.firebase:firebase-analytics:17.4.4'
}
apply plugin: 'com.google.gms.google-services'

【问题讨论】:

    标签: flutter


    【解决方案1】:

    你可以试试:

    1. 停止调试并重新构建应用程序。
    2. 清理构建缓存:
      flutter clean
    3. 在终端运行:
      flutter channel master
      flutter upgrade

    【讨论】:

    • 又是同样的问题
    猜你喜欢
    • 2020-12-05
    • 1970-01-01
    • 2022-07-08
    • 1970-01-01
    • 2013-06-01
    • 1970-01-01
    • 2021-11-09
    • 2018-11-19
    • 1970-01-01
    相关资源
    最近更新 更多