Migration to androidX missing in Android Studio

10k Views Asked by At

I am trying to migrate my project to androidX. The project i am trying to migrate is based on android support libraries AppCompat. In the Developer Documentation it says that you can migrate to AndroidX by doing the Following: Android Studio -> Refactor -> Migrate to AndroidX But when i am following these steps, i end up at Refactor, because i only have got the option Migrate to AppCompat. I am not sure what to do.

Additional Info:
Android Studio Version: 3.1.4(Stable Channel)
Android SDK Tools Version: 26.1.1

Thanks for any help!

3

There are 3 best solutions below

6
On BEST ANSWER

"Refactor to AndroidX" option is available for AndroidStudio 3.2 stable and later. https://developer.android.com/studio/

0
On

If you have the same problem after you updated AndroidStudio to 3.2 or later, you can modify your ***.kts to ***.gradle. I solved my problem this way.

1
On

Switch to "Android" or "Project" tab in the file navigation window. And right click on your parent folder and go to refactor, there listed "Migrate to android" option. It is very simple. In case of any mistakes in migration we can switch back to appcompat version using "migrate to appcompat" under same menu.