Remove import of com.facebook.react.ReactSettingsExtension (#44850)

Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/44850

I'm removing this line from settings.gradle:
```
import com.facebook.react.ReactSettingsExtension
```
and just using a fully qualified class name in the `configure{}` block
as imports cannot be conditionally included and is making hard for RNTA
to integrated those changes.

Changelog:
[Internal] [Changed] - Remove import of `com.facebook.react.ReactSettingsExtension`

Reviewed By: huntie

Differential Revision: D58354443

fbshipit-source-id: bc45516661318021a042e1c5921e28d7217cacbc
This commit is contained in:
Nicola Corti 2024-06-10 03:26:34 -07:00 committed by Facebook GitHub Bot
parent 6937c7044b
commit feeb4b773b
3 changed files with 3 additions and 7 deletions

View File

@ -6,10 +6,9 @@
*/
// Autolinking has now moved into the React Native Gradle Plugin
import com.facebook.react.ReactSettingsExtension
pluginManagement { includeBuild("../node_modules/@react-native/gradle-plugin") }
plugins { id("com.facebook.react.settings") }
extensions.configure(ReactSettingsExtension){ ex -> ex.autolinkLibrariesFromCommand() }
extensions.configure(com.facebook.react.ReactSettingsExtension){ ex -> ex.autolinkLibrariesFromCommand() }
rootProject.name = 'HelloWorld'
include ':app'

View File

@ -1,7 +1,6 @@
import com.facebook.react.ReactSettingsExtension
pluginManagement { includeBuild("../node_modules/@react-native/gradle-plugin") }
plugins { id("com.facebook.react.settings") }
extensions.configure(ReactSettingsExtension){ ex -> ex.autolinkLibrariesFromCommand() }
extensions.configure(com.facebook.react.ReactSettingsExtension){ ex -> ex.autolinkLibrariesFromCommand() }
rootProject.name = 'HelloWorld'
include ':app'
includeBuild('../node_modules/@react-native/gradle-plugin')

View File

@ -5,8 +5,6 @@
* LICENSE file in the root directory of this source tree.
*/
import com.facebook.react.ReactSettingsExtension
pluginManagement {
repositories {
mavenCentral()
@ -38,7 +36,7 @@ plugins {
id("com.facebook.react.settings")
}
configure<ReactSettingsExtension> {
configure<com.facebook.react.ReactSettingsExtension> {
autolinkLibrariesFromCommand(
workingDirectory = file("packages/rn-tester/"), lockFiles = files("yarn.lock"))
}