I'm trying to import compose sample projects, but I'm facing this error:
Invalid injected android support version '202.7660.26.42.7322048', expected to be of the form 'w.x.y.z'
The android studio is currently updated to its newest version 4.2.
How can I fix this?
If you want to use Jetpack Compose in an existing project, you'll need to configure your project with required settings and dependencies.
For the best experience developing with Jetpack Compose, download and install Android Studio. It includes many smart editor features, such as new project templates and the ability to immediately preview your Compose UI and animations.
The version 202.7660.26.42.7322048
is
Android Studio 4.2
Build #AI-202.7660.26.42.7322048, built on April 29, 2021
As suggested in the current (1.0.0-beta08
) official setup of compose you should use the Android Studio in the beta channel:
Android Studio Arctic Fox | 2020.3.1 Beta 03
Open Project Structure dialog (Ctrl+Alt+Shift+S) and select Android Gradle plugin version to 4.2.1 ( >4.2.1 has this bug till version 7.1.0-alpha01) and Gradle version to 7.0.2.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With