简体   繁体   English

如何在离子 android 中将我的应用程序的目标 API 级别从 29 更改为 30

[英]how to change my app's target API level from 29 to 30 in ionic android

Created an ionic android app with the Cordova plugin.使用 Cordova 插件创建了一个离子 android 应用程序。 When tried to upload the generated apk file to the play store, got an error:尝试将生成的 apk 文件上传到 play store 时,出现错误:

"Your app currently targets API level 29 and must target at least API level 30 to ensure it is built on the latest APIs optimized for security and performance. Change your app's target API level to at least 30". “您的应用当前针对 API 级别 29,并且必须至少针对 API 级别 30,以确保其构建在针对安全性和性能优化的最新 API 之上。将您的应用的目标 ZDB974238714CA8DE6434A7CE1D3803A 级别更改为至少。”

Corrected and uploaded the apk, next time while trying to upload the newly generated apk got the same error, Is any persistent solution for it??更正并上传了apk,下次尝试上传新生成的apk时遇到同样的错误,有什么持久的解决方案吗?

Corrected in config.xml, do I need to change anywhere else?在 config.xml 中更正,我需要在其他任何地方进行更改吗?

在此处输入图像描述

ionic version: 5.4.16离子版本:5.4.16
cordova version: 11.0.0 cordova 版本:11.0.0

Update your Cordova CLI to version 11, then it will download cordova-android 10.x when you run cordova platform add android that already target SDK 30 by default. Update your Cordova CLI to version 11, then it will download cordova-android 10.x when you run cordova platform add android that already target SDK 30 by default. If you already have a cordova-android platform, you'll have to remove it first and also remove whitelist plugin as it's not integrated into the platform如果您已经有一个 cordova-android 平台,则必须先将其删除并删除白名单插件,因为它没有集成到平台中

cordova platform rm android
cordova plugin rm cordova-plugin-whitelist
cordova platform add android

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何让我的 ionic 应用程序面向 API 级别 28 及以上 - How do i get my ionic app to target API level 28 and Above 如何将我的 ionic 应用程序连接到同一页面中的两个不同的 API URL? 如何将第一个 url 数据中的 id 传递给第二个 url? - How can I connect my ionic app to two different API URLS in the same page? how to pass the id from the first url's data to the second url? 离子应用程序以API级别25为目标,并且必须至少以API级别26为目标 - Ionic application targets API level 25 and must target at least API level 26 如何使用我的离子2应用程序打开Android手机的安全设置? - How to open the secure settings of the android phone with my ionic 2 app? 如何从ionic 2移动应用程序连接到c#rest api? - how to connect to c# rest api from ionic 2 mobile app? 如何从支付网站重定向回我的 ionic 应用程序 - how to redirect back to my ionic app from a payment site 从Angular / IOnic App到Rails API的CRUD - CRUD from Angular/IOnic App to rails API 为什么我的API调用从Ionic应用程序返回401,而不从Postman返回401? - Why does my API call return a 401 from an Ionic app but not Postman? 如何在不安装/运行 android 工作室的情况下在模拟器上运行我的离子 android 应用程序? - How do i run my ionic android app on an emulator without installing/running the android studio? 当 Ionic 3 中的 Firestore 集合发生变化时,如何实现应用范围的通知功能? - How do I implement a app-wide notification feature when there is a change in my Firestore collection in Ionic 3?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM