Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.4k views
in Technique[技术] by (71.8m points)

ionic framework - ionic4 base64 native plugin not working in android target sdk 29

In my ionic app i integrated ionic4 native base64 plugin, it was working fine in all android os mobiles when my android target sdk 28. due to play store restriction i have changed tragetSDK 28 to 29 then it is not working in android os 10 mobile. please can any one help how to fix it.

question from:https://stackoverflow.com/questions/65624260/ionic4-base64-native-plugin-not-working-in-android-target-sdk-29

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

In Android, in the build.gradle(app) file, change target SDK to targetSdkVersion 30 or targetSdkVersion 29.

Then go to your AndroidManifest.xml and add this line android:requestLegacyExternalStorage="true" in the application tag like that :

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    >

    <application
        android:allowBackup="false"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:roundIcon="@mipmap/ic_launcher_round"
        android:supportsRtl="true"
        android:theme="@style/AppTheme"
        android:requestLegacyExternalStorage="true">

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...