title: How to solve Google Play unoptimized APK problem on Flutter apps?
body: <p>With my Flutter app, I get this error on Google Play</p>
  
  <blockquote>
    <p>Unoptimized APK Warning:</p>
    
    <p>This APK results in unused code and resources being sent to users.
    Your app could be smaller if you used the Android App Bundle. By not
    optimizing your app for device configurations, your app is larger to
    download and install on users' devices than it needs to be. Larger
    apps see lower install success rates and take up storage on users'
    devices.</p>
    
    <p>Resolution:</p>
    
    <p>Use the Android App Bundle to automatically optimize for device
    configurations, or manage it yourself with multiple APKs.</p>
  </blockquote>
  
  <p>I have added them in android/app/build.gradle but it didn't solve my issue:</p>
  
  <pre><code>buildTypes {
         release {
             signingConfig signingConfigs.release
  
              minifyEnabled true
              shrinkResources false
              useProguard true
  
              proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
         }
     }
  </code></pre>