[react-native] No resource found. SDK 26

1. [react-native] No resource found. SDK 26

Paulo Henrique dos Santos Souza
devpaulosouza

Enviado em 15/12/2017 - 10:30h

Olá,

Estou com problemas ao instalar o react-native-fbsdk. O projeto roda normalmente até que eu tente instalá-lo.

Já olhei vários links do stackoverflow, forums, issues no GitHub e não consigo resolver isso. Por favor, se souberem como resolve isso me ajudem, estou há um tempão travado nisso.

Quando tento dar o sync no Android Studio aparece o seguinte erro:

Error:(15, 21) No resource found that matches the given name: attr 'android:keyboardNavigationCluster'.


Versão que estou utilizando:
 
react-native-cli: 2.0.1
react-native: 0.51.0
react: 16.0.0,
react-native-fbsdk: ^0.6.3


O meu build.gradle é o seguinte:
 
apply plugin: "com.android.application"

import com.android.build.OutputFile

project.ext.react = [
entryFile: "index.js"
]

apply from: "../../node_modules/react-native/react.gradle"

/**
* Set this to true to create two separate APKs instead of one:
* - An APK that only works on ARM devices
* - An APK that only works on x86 devices
* The advantage is the size of the APK is reduced by about 4MB.
* Upload all the APKs to the Play Store and people will download
* the correct one based on the CPU architecture of their device.
*/
def enableSeparateBuildPerCPUArchitecture = false

/**
* Run Proguard to shrink the Java bytecode in release builds.
*/
def enableProguardInReleaseBuilds = false

def versionOverrides = [
"com.facebook.android:facebook-android-sdk": "4.28.0",
]

android {
compileSdkVersion 27
buildToolsVersion "27.0.2"

defaultConfig {
applicationId "com.androidlogin"
minSdkVersion 16
targetSdkVersion 27
versionCode 1
versionName "1.0"
ndk {
abiFilters "armeabi-v7a", "x86"
}
}
splits {
abi {
reset()
enable enableSeparateBuildPerCPUArchitecture
universalApk false // If true, also generate a universal APK
include "armeabi-v7a", "x86"
}
}
buildTypes {
release {
minifyEnabled enableProguardInReleaseBuilds
proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
}
}
// applicationVariants are e.g. debug, release
applicationVariants.all { variant
variant.outputs.each { output
// For each separate APK per architecture, set a unique version code as described here:
// http://tools.android.com/tech-docs/new-build-system/user-guide/apk-splits
def versionCodes = ["armeabi-v7a":1, "x86":2]
def abi = output.getFilter(OutputFile.ABI)
if (abi != null) { // null for the universal-debug, universal-release variants
output.versionCodeOverride =
versionCodes.get(abi) * 1048576 + defaultConfig.versionCode
}
}
}
}

dependencies {
compile project(':react-native-fbsdk')
compile fileTree(dir: "libs", include: ["*.jar"])
compile "com.android.support:appcompat-v7:27.0.2"
compile "com.facebook.react:react-native:0.20.1" // From node_modulescompile 'com.android.support:appcompat-v7:26+'
compile 'com.android.support:design:27.0.2'
compile 'com.android.support:recyclerview-v7:27.0.2'
compile 'com.android.support:cardview-v7:27.0.2'
}

// Run this once to be able to run the application with BUCK
// puts all compile dependencies into folder libs for BUCK to use
task copyDownloadableDepsToLibs(type: Copy) {
from configurations.compile
into 'libs'
}



Já procurei em vários tópicos do stackOverflow mas não acho nenhuma solução =/

Links que testei por ultimo:
https://stackoverflow.com/questions/47673568/react-native-fbsdk-unknown-issue
https://stackoverflow.com/questions/45301203/no-resource-found-that-matches-the-given-name-attr-andr...









Patrocínio

Site hospedado pelo provedor HostGator.

Artigos

Notícias

Tópicos

Top 10 do mês