Use AndroidX in a project

Use AndroidX in a new project
gradle.properties file:

android.useAndroidX=true
android.enableJetifier=true

Migrate an existing project using Android Studio

select Refactor > Migrate to AndroidX from the menu bar

References
https://developer.android.com/topic/libraries/support-library/androidx-overview?utm_source=android-studio&utm_medium=studio-assistant#migration
https://developer.android.com/topic/libraries/support-library/refactor#migrate