I followed both this tutorials tutorial 1 and tutorial 2
I added all dependencies in build.gradle file.
and I also added this
//(MainApplication) Manual ReactPackage Setup here...
apply from: file("../../node_modules/@react-native-community/cli-platform-
android/native_modules.gradle");
applyNativeModulesAppBuildGradle(project)
But , I have the following error

How can I solve this ?