title: error: cannot find symbol import androidx.annotation.Nullable;
body: <p>I installed Jetifier to resolve an issue with react-native-gesture-handler but now I'm getting this error:</p>
  
  <pre><code>&gt; Task :expo-constants:compileDebugJavaWithJavac FAILED
  C:\ioweu\node_modules\expo-constants\android\src\main\java\expo\modules\constants\ConstantsService.java:6: error: cannot find symbol
  import androidx.annotation.Nullable;
                            ^
    symbol:   class Nullable
    location: package androidx.annotation
  C:\ioweu\node_modules\expo-constants\android\src\main\java\expo\modules\constants\ConstantsService.java:51: error: cannot find symbol
    @Nullable
     ^
    symbol:   class Nullable
    location: class ConstantsService
  2 errors
  
  FAILURE: Build failed with an exception.
  </code></pre>
  
  <p>I'm working with React Native and Android Studio. I'm still new to all of this so any help is appreciated.</p>
  
  <p>Here are my dependencies:</p>
  
  <pre><code>dependencies {
      implementation project(':react-native-gesture-handler')
      implementation project(':react-native-image-picker')
      implementation project(':react-native-splash-screen')
      implementation project(':react-native-screens')
      implementation project(':react-native-reanimated')
      implementation fileTree(dir: "libs", include: ["*.jar"])
      implementation "com.android.support:appcompat-v7:${rootProject.ext.supportLibVersion}"
      implementation "com.facebook.react:react-native:+"  // From node_modules
  
      addUnimodulesDependencies()
  }
  </code></pre>
  
  <p>To solve my earlier errors, I followed the content here <a href="https://github.com/facebook/react-native/issues/25483#issuecomment-508446776" rel="noreferrer">https://github.com/facebook/react-native/issues/25483#issuecomment-508446776</a>, which I understand changed my project to use AndroidX.</p>
  
  <p>To solve these two new errors, I tried adding the line <code>implementation "com.android.support:support-annotations:+"</code> to my gradle.build dependencies and then run ./gradlew clean but it didn't work or I did it wrong. I think I'm going about it the wrong way.</p>
  
  <p>Edit: I added <code>implementation "androidx.annotation:annotation:1.1.0"</code> but it didn't solve anything yet.</p>
  
  <p>Edit 2: I tried the guide here: <a href="https://flutter.dev/docs/development/packages-and-plugins/androidx-compatibility#recommended-use-android-studio-to-migrate-your-app" rel="noreferrer">https://flutter.dev/docs/development/packages-and-plugins/androidx-compatibility#recommended-use-android-studio-to-migrate-your-app</a>. Steps 1, 3 and 4 were the only ones that seemed to apply to me.</p>
  
  <p>This resulted in the following error:</p>
  
  <pre><code>error: package android.support.v7.app does not exist
  import android.support.v7.app.AppCompatActivity;
  </code></pre>
  
  <p>Edit 3: Issue (with my splash screen class) was fixed by adding <code>implementation "androidx.appcompat:appcompat:1.1.0"</code> to my build.gradle and replacing </p>
  
  <pre class="lang-java prettyprint-override"><code>import android.support.v7.app.AppCompatActivity;
  </code></pre>
  
  <p>with </p>
  
  <pre class="lang-java prettyprint-override"><code>import androidx.appcompat.app.AppCompatActivity;
  </code></pre>
  
  <p>My issue is now fixed. I'm sorry for asking questions which may seem like a hinderance to people more well versed in this.</p>