Cannot import android.support.v4.app.Fragment

Hi,

I’m having a hard time importing this fragment class. Alt+enter doesn’t show any options that are available in listing 7.15.

Here is the available Fragment class to import

I have do some research online and and find out that I need to install and reference support library 4 by adding this line to the module app build.gradle file.
implementation 'com.android.support:support-v4:28.0.0'

After recompiling, syncing the gradle file the error is still there.

I have also tried the solutions in this thread, but none of the solutions worked for me.

How can I fix this?

edit: I have tried to update gradle.properties with the new configuration, but I received Manifest Merger Failed error.

смог ли ты найти решение этой проблемы?
у меня тоже только один вариант Fragment > import androidx.fragment.app.Fragment;

возможно это из-за новой версии, и сейчас уже не актуально

Hey, did you figure this one out? I am having the same problem, please help me.

As of today, per this post kotlin - Can't Import android.support.v4.app.Fragment but can import FragmentManager - Stack Overflow I suspect it is just “import androidx.fragment.app.Fragment”.