Migration from 5.X.X to 5.2+

Data binding issue after SDK update to 5.2+

After having updated SDK to 5.2+ you could get issues with data binding stack trace as below :

--------- beginning of crash
2021-08-23 17:12:19.602 19197-19197/? E/AndroidRuntime: FATAL EXCEPTION: main
    Process: com.app.dev, PID: 19197
    java.lang.NoClassDefFoundError: Failed resolution of: Lcom/appspanel/databinding/ActivityInterstitialBinding;
        at com.appspanel.manager.interstitial.APInterstitialActivity.onCreate(APInterstitialActivity.kt:38)

It imply you don't have jetpack view binding enabled on your app.
Let me introduce you the way to fix it...

Jetpack view binding

Kotlin Android Extensions is deprecated, which means that using Kotlin synthetics for view binding is no longer supported. Apps Panel SDK use the new way to bind layout so If your app uses Kotlin synthetics for view binding, you need at least to enable Jetpack view binding by adding the following property in the build.gradle file of your app :

android {
    ...
    buildFeatures {
        viewBinding = true
    }
}

Sources : https://developer.android.com/topic/libraries/view-binding/migration#kts

After project sync, the issue should be gone ! 👋