Can we upgrade android compileSdkVersion to 33 from 32 without upgrading capacitor

I am working on an ionic/angular application with Capacitor. I got an email from Google, and then we had to upgrade the Android SDK version to 33 from 32. When I upgraded the compileSdkVersion I got an error when building the APK.

C:\Users\sanjeewa\Desktop\The link\link\link-client\node_modules\@capacitor\android\capacitor\src\main\java\com\getcapacitor\ error: cannot find symbol
  symbol:   method setAppCacheEnabled(boolean)
  location: variable settings of type WebSettings

Does anyone know how to fix this?

You can fix it updating to Capacitor 5

1 Like

If you cant update to v5 capacitor, but you can simply in node modules /@capacitor/android/capacitor/src/main/java/com/getcapacitor/ remove line with setAppCacheEnabled(boolean) and then it should works