Home > Software engineering >  Error on AndroidStudio when building app Ionic/Capacitor
Error on AndroidStudio when building app Ionic/Capacitor

Time:10-08

i'm developing an app with Ionic & Capacitor for android. When I try to build the project in Android Studio I have this error:

Caused by: org.gradle.internal.metaobject.AbstractDynamicObject$CustomMessageMissingMethodException: Could not find method compile() for arguments [me.leolin:ShortcutBadger:1.1.22@aar] on object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler.

Searching on internet I should replace 'compile' with implementation to match gradle version, but I haven't any compile in my code nor in the build.gralde.

How can I solve it?

CodePudding user response:

Probably this could work.

https://forum.ionicframework.com/t/android-build-error-after-migration-from-capacitor-3-to-capacitor-4/226645

It is an older Post but it mentiont your error. I got the same after upgrading my app but with installation of the mentiont plugin i got it to work.

CodePudding user response:

I had also the same problem and user14802832's solution helped me to generate apks on my project again. Thanks!

  • Related