Language change is working before uploading to Google Play Store but not after uploading to play store . Why?

后端 未结 2 1100
醉酒成梦
醉酒成梦 2021-02-18 15:47
  • In My Application There are two language.
  • If I download application from device which has English as default language.Then it is not changing to Chinese strings.x
2条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2021-02-18 16:12

    As @Vrushi Patel said, this is related to Android App Bundles. To fix this you have to edit the android.bundle block in your base module’s build.gradle as shown below as mentioned in the official documentation:

    android {
    // When building Android App Bundles, the splits block is ignored.
    splits {...}
    
    // Instead, use the bundle block to control which types of configuration APKs
    // you want your app bundle to support.
    bundle {
        language {
            // Specifies that the app bundle should not support
            // configuration APKs for language resources. These
            // resources are instead packaged with each base and
            // dynamic feature APK.
            enableSplit = false
        }
        density {
            // This property is set to true by default.
            enableSplit = true
        }
        abi {
            // This property is set to true by default.
            enableSplit = true
        }
    }
    }
    

提交回复
热议问题