android - ionic4 和 firebase 推送通知问题
问题描述
我在构建应用程序时遇到以下错误:错误:请通过更新 google-services 插件的版本来修复版本冲突(有关最新版本的信息,请访问https://bintray.com/android/android-tools /com.google.gms.google-services/)或将 com.google.android.gms 的版本更新到 10.+。
在我的 android 应用程序中,我有以下依赖项:
电容器.build.gradle:
implementation "com.google.firebase:firebase-core:10.+"
implementation "com.google.firebase:firebase-messaging:10.+"
implementation "com.google.android.gms:play-services-location:16.+"
电容器.build.gradle:
implementation 'com.google.firebase:firebase-messaging:18.0.0'
构建.gradle:
try {
def servicesJSON = file('google-services.json')
if (servicesJSON.text) {
apply plugin: 'com.google.gms.google-services'
}
} catch(Exception e) {
logger.warn("google-services.json not found, google-services plugin not applied. Push Notifications won't work")
}
解决方案
推荐阅读
- java - JAVA:Stripe webhook 错误:未找到与有效负载的预期签名匹配的签名
- android - 如何制作像Linkedin这样的进度条来显示个人资料状态?
- python - 循环和计数python 2d数组
- html - 如何在危险的SetInnerHTML中设置默认值?
- azure - Azure 静态网站 - 在 Chrome 中显示旧内容
- java - Java Spring Test Autowired Controller 为空错误
- python - 无法在 Django 中显示静态图像和加载 CSS
- python - 在pyqt中使用sceneEventFilter捕获悬停事件
- api - WSO2 ESB 返回一串 json 结构
- flutter - Sliver Appbar [Collapsing Toolbar] 在 Flutter 中从左到中动画标题