Task :react-native-gesture-handler:compileDebugJavaWithJavac FAILED code example

Example 1: Execution failed for task ':react-native-gesture-handler:compileDebugJavaWithJavac'

//Add the following to the gradle.properties to activate AndroidX
android.useAndroidX=true
android.enableJetifier=true

// Run the following commands in the root of your project
npm i jetifier
npx jetifier

Example 2: Execution failed for task ':react-native-gesture-handler:compileReleaseJavaWithJavac'.

npm i jetifier
npx jetify

Tags:

Misc Example