upgrade-support icon indicating copy to clipboard operation
upgrade-support copied to clipboard

layout error

Open Jitesh0404 opened this issue 1 year ago • 29 comments

e: file:///C:/Users/Jitesh/OneDrive/Desktop/gurujiastroapp/node_modules/@react-native/gradle-plugin/settings-plugin/src/main/kotlin/com/facebook/react/ReactSettingsExtension.kt:26:16 Unresolved reference: layout

Here is my build.gradle file

buildscript { ext { buildToolsVersion = "34.0.0" minSdkVersion = 21 compileSdkVersion = 34 targetSdkVersion = 34 // Remove any sourceCompatibility and targetCompatibility here if present // Instead, use: androidXCore = "1.10.1" kotlinVersion = "1.8.0" reactNativeGradlePluginVersion = "5.0.4" } repositories { google() mavenCentral() } dependencies { classpath("com.android.tools.build:gradle") classpath("com.facebook.react:react-native-gradle-plugin") classpath("org.jetbrains.kotlin:kotlin-gradle-plugin") classpath("com.facebook.react:react-native-gradle-plugin:$reactNativeGradlePluginVersion")

}

} apply plugin: "com.facebook.react.rootproject" // Top-level build file where you can add configuration options common to all sub-projects/modules. plugins { // ...

// Add the dependency for the Google services Gradle plugin

// id 'com.google.gms.google-services' version '4.4.1' apply false

}

Jitesh0404 avatar Nov 08 '24 10:11 Jitesh0404

same issue

lyderdev avatar Nov 12 '24 10:11 lyderdev

Same issue any one found any solution ?

NupurKukkar avatar Nov 15 '24 12:11 NupurKukkar

+1

Jin-seop avatar Nov 18 '24 01:11 Jin-seop

+1

borisYojji avatar Nov 19 '24 09:11 borisYojji

Same issue any one found any solution ?

jaci001 avatar Nov 19 '24 16:11 jaci001

+1

aamiranwar001 avatar Nov 20 '24 13:11 aamiranwar001

+1

andrazperson avatar Nov 21 '24 11:11 andrazperson

+1

kenteman avatar Nov 25 '24 06:11 kenteman

Same after upgrading to RN latest version.

moniquealtero avatar Nov 25 '24 18:11 moniquealtero

Same issue after upgrading to RN 0.75.4

zjkuang avatar Nov 26 '24 13:11 zjkuang

+1

ReijiTBK avatar Dec 03 '24 10:12 ReijiTBK

+1

Purushottam18 avatar Dec 04 '24 09:12 Purushottam18

+1. EDIT to add: upgrading to RN 0.76.

ig-aellison avatar Dec 04 '24 13:12 ig-aellison

Updating android studio to android-studio-2024.2.1.11 can solve this problem

yangjianger avatar Dec 11 '24 06:12 yangjianger

+1, I updated android-studio, but it didn't solve the problem. I updated the node, and I've been stuck with this for days.

jaehuiLee avatar Dec 14 '24 20:12 jaehuiLee

+1 Same RN 0.76.5

GlennAzx avatar Dec 18 '24 10:12 GlennAzx

+1

sardarasmita avatar Dec 18 '24 10:12 sardarasmita

Same issue on upgrading from 0.75.1 to 0.76

alok1upadhyay avatar Dec 20 '24 14:12 alok1upadhyay

Same issue

hamidkeyhani avatar Dec 23 '24 09:12 hamidkeyhani

Manually updating each file from old to new using the update helper fixed it for me. https://react-native-community.github.io/upgrade-helper/

GlennAzx avatar Dec 23 '24 13:12 GlennAzx

Same issue when created new project (0.76.5)

srahul99 avatar Jan 09 '25 09:01 srahul99

Same issue while updating RN from 0.71.14 to 0.77 Android Studio: 2024.1.2 Mac OS: 14.6.1

Thanks

akhilsanker avatar Jan 23 '25 09:01 akhilsanker

+1 RN 0.73.4 to 0.76.6

hernanmateo avatar Jan 26 '25 15:01 hernanmateo

This is caused by a dependency that is using deprecated com.android.support libraries. By the moment, I solved it by (re)enabling jettifier (discontinued) in gradle.properties file:

android/gradle.properties android.enableJetifier=true

hernanmateo avatar Jan 27 '25 13:01 hernanmateo

What fixed it for me was to add distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-all.zip to android/gradle/wrapper/gradle-wrapper.properties. I had forgotten to update this in the migration process.

codrin-lanterne avatar Jan 29 '25 15:01 codrin-lanterne

+1 someone please share the solution.

Anushka3001 avatar Feb 12 '25 11:02 Anushka3001

I've been battling this problem for days now. I've tried all the solutions written here but it's still not resolved. Can someone help?

NaotoUeyanagi avatar Jun 04 '25 05:06 NaotoUeyanagi

I'm battling this too. I suspect one of my dependencies is causing the issue, but I haven't determined which one.

mbrimmer83 avatar Jun 07 '25 00:06 mbrimmer83

I'm battling this too. I suspect one of my dependencies is causing the issue, but I haven't determined which one.

I was able to solve this. My issue was react-native-emoji-modal had an older react-native version. This caused an older version of @react-native/gradle-plugin to be installed and they conflicted. Try running npm list react-native @react-native/gradle-plugin and ensure all your deps are updated properly.

mbrimmer83 avatar Jun 07 '25 02:06 mbrimmer83