Socket
Socket
Sign inDemoInstall

@react-native/gradle-plugin

Package Overview
Dependencies
0
Maintainers
11
Versions
308
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @react-native/gradle-plugin

⚛️ Gradle Plugin for React Native


Version published
Weekly downloads
1.4M
decreased by-0.31%
Maintainers
11
Created
Weekly downloads
 

Package description

What is @react-native/gradle-plugin?

The @react-native/gradle-plugin npm package is designed to enhance and simplify the integration of React Native projects with the Android build system, Gradle. It provides a set of Gradle scripts and configurations that automate the process of building and bundling React Native code and assets into Android applications. This plugin streamlines the development workflow, making it easier to include React Native components in Android apps, manage dependencies, and customize the build process.

What are @react-native/gradle-plugin's main functionalities?

Automatic linking of project dependencies

Automatically links all project dependencies declared in your `package.json` file with your Android project, eliminating the need for manual linking. This feature simplifies the process of adding and updating React Native modules that include native Android code.

apply plugin: '@react-native/gradle-plugin'

Customizable build configurations

Allows for customization of build configurations, such as specifying the entry file for the React Native bundle or enabling bundling for release builds. This feature provides flexibility in how React Native components are built and integrated into your Android app.

project.ext.react = [
    entryFile: 'index.js',
    bundleInRelease: true
]

Asset bundling and packaging

Automates the process of bundling JavaScript code and assets (such as images and fonts) into your Android application. This ensures that all necessary React Native components and resources are included in the app package, ready for distribution.

bundleReleaseJsAndAssets {
    dependsOn 'mergeReleaseResources'
    dependsOn 'bundleReleaseJsAndAssets'
}

Other packages similar to @react-native/gradle-plugin

Changelog

Source

v0.73.0

Breaking

  • Bump minimum Node JS version to 18 (2eb25cbdbe)
  • Require C++ 20 when including renderer headers (3b5bea01d0 by @NickGerleman)
  • Remove included flow-typed/ directory from the react-native package (4540668c15 by @huntie)
  • per-node pointScaleFactor (dce7242ab6 by @NickGerleman)
  • Remove "UseLegacyStretchBehaviour" functions (c35ff13a58 by @NickGerleman)
  • Remove YGConfigGetInstanceCount (858173280f by @NickGerleman)
  • Remove interpolateProps functionality from ComponentDescriptor to fix circular dependency between react/renderer/core and react/renderer/components/view (bae63d492f)
  • Migrate from native CallInvoker to NativeMethodCallInvoker (b70f186b53 by @RSNara)
  • Change how we set cmake policy (2b932c3820 by @NickGerleman)
  • Add YGErrata integration within C ABI (0fd0f56f20 by @NickGerleman)
  • Set runtimeConfig provider for the Template (2de964cfd2 by @dmytrorykun)
Android specific
  • Fix: role="searchbox" should assign "SearchField" trait on iOS (2749fbca9a by @mdjastrzebski)
  • Renamed FabricMountItem.* files to MountItem.* to better match the name of the struct. (49f1237526)
  • Deleting warnOnLegacyNativeModuleSystemUse (9859fbc2ec by @philIip)
  • Do not enable excludeYogaFromRawProps feature flag, if you need to pass layout props to Java view managers when using new architecture (88e19c0ce6 by @zeyap)
  • Default to ignoring cached Metro bundle when offline (2d6106055b by @motiz88)
  • W3CPointerEvents: change click event from direct to bubbling (61eb9b4453)
  • Fix ReactTextView setPadding applying logic error (d8ced6f895 by @jcdhlzq)
  • Add view getter on RCTRootView / `RCTFabricSurfaceHostingProxyRootView (33e0521788 by @zoontek)
  • Remove support for Android API < 23 in ReactEditText (1904e8036a by @mdvacca)
iOS specific

Added

Android specific
iOS specific

Changed

Android specific
  • Convert the app template to Kotlin (c1c22ebacc by @cortinico)
  • Upgrade target sdk version to 34 (a6b0984893)
  • Bump NDK to 25 (28deaa3a71 by @szymonrybczak)
  • Remove Flipper actions in Dev Menu, add new Open Debugger action (3bc402f612 by @huntie)
  • Add scrollEventThrottle prop support for android (777934ec3a)
  • Don't display the PopupWindow when current activity is in a bad state (cee5dceac7)
  • React trees will be unmounted when the application is reloaded (e133100721 by @javache)
  • Fix crash "lateinit property initialProps has not been initialized" (188eceec98)
  • Deprecating createNativeModules method from ReactPackage interface recommending using getModule instead in the new architecture of React Native (33181ef8af by @mdvacca)
  • Introducing getModule method into ReactPackage interface, defaulting to null. This method will be used in the Stable API of React Native (da8616ec69 by @mdvacca)
  • Update Java tests to Kotlin for the referenced file (3dbb759506 by @stewartsum)
  • Deprecate JSCJavaScriptExecutorFactory and JSCJavaScriptExecutor, use com.facebook.react.jscexecutor instead (0cac88fa65 by @mdvacca)
  • Throw ReactNoCrashSoftException when handle memeory pressure to avoid crash (fa9ea8326e)
  • Throw Error in dispatchViewManagerCommand when non-numeric tag is passed for easier debugging (0519c11acd by @hsource)
  • Moved ReactFontManager to a common package (7341f9abdc by @fkgozali)
  • Throw Error in dispatchViewManagerCommand when non-numeric tag is passed for easier debugging (ff1972daba by @hsource)
  • Fresco to 3.0.0 (823839bcc1 by @cortinico)
  • Avoid duplicate destroy on same thread (43f7781c87)
  • Use new getCanonicalName and getMessage methods exposed by fbjni (6c729acd12 by @krystofwoldrich)
  • Changed the scope of setJSEngineResolutionAlgorithm to public from private. Brownfield apps should be able to setup the JSResolutionAlgorithm before hand. (cb376dd0d8 by @SparshaSaha)
  • Java to 17 and AGP to 8.0.2 (9f7dddf1ac by @cortinico)
  • Use reference Yoga CMake Build (6764adafe4 by @NickGerleman)
  • Enable Template with Bridgeless (8b2f324a9b)
  • Kotlin to 1.8.0 and JDK Toolchain to 11 (74987b6fca by @cortinico)
  • Deprecate APIs that are deprecate only on JavaDoc (1be65baf29 by @cortinico)
  • Gradle to 8.1 (74f256b6f0 by @cortinico)
  • "Open Debugger" is no longer available for remote JS debugging from the Dev Menu (non-Hermes). Please use NativeDevSettings.setIsDebuggingRemotely(). (361a944348 by @huntie)
iOS specific
  • Remove Flipper actions in Dev Menu, add new Open Debugger action (5bfc507655 by @huntie)
  • Moved the min iOS version to 13.4 (610b14e4f3 by @cipolleschi)
  • TurboModules are now exposed to JS as the prototype of a plain JS object, so methods can be cached (20dba39dab by @javache)
  • Restored cancelable option in Pressability configuration to not block native responder, and instead introduced a new optional blockNativeResponder boolean option to accomplish the same thing. (30e2345b26 by @yungsters)
  • Scroll ScrollView text fields into view with automaticallyAdjustsScrollIndicatorInsets (9ca16605e0 by @adamaveray)
  • Remove Xcode 15 _LIBCPP_ENABLE_CXX17_REMOVED_UNARY_BINARY_FUNCTION workaround for boost (b9f0bdd12d by @Kudo)
  • Updated comment in RCTBundleURLProvider.h to instance correct jsBundleURLForBundleRoot:fallbackExtension method. (d208dc422c by @JulioCVaz)
  • Set the new arch flag based on the React Native version. (a8d268593a by @cipolleschi)
  • Add RCTPlatformName to RCTConstants.h (046ae12a6d by @Saadnajmi)
  • Use the runtime scheduler in the old Architecture (2692f206a6 by @cipolleschi)
  • Set DEFINES_MODULE xcconfig in React-RCTAppDelegate to generate a module map for this pod (7c79e3107f by @tsapeta)
  • Move .m to .mm to make obj-c and C++ headers compatible (42d67452eb)
  • Remove deprecated uses of UIActivityIndicatorViewStyle (62e9faefd5 by @Saadnajmi)
  • Fix setRuntimeConfigProvider called multiple times error (637ffb175d)
  • Set initial AppState status to "inactive" instead of "unknown" (54a5ff9745 by @louiszawadzki)
  • Return animated values to JS for natively driven animations (b0485bed09 by @genkikondo)
  • Disabled bitcode for Hermes prebuilts (de6bfec82a by @cipolleschi)
  • Make RNTester use RCTAppDelegate (680cbe757b by @cipolleschi)
  • Changed AppDelegate template to avoid retaining TurboModuleManager. (ec1ab73674 by @javache)
  • Migrate RNTester to Bridgeless (d3c28d28a9)
  • Re-organise BridgelessApple files to keep proper header file include structure (736dd5a3c0)

Deprecated

Android specific
iOS specific
  • Deprecate get_default_flags in Ruby scripts (f60b9f695e by @cipolleschi)
  • Use -[RCTTurboModuleManager installJSBindings:] instead of -[RCTTurboModuleManager installJSBindingWithRuntimeExecutor:] (7fb9e4f46c by @javache)

Removed

Android specific
iOS specific

Fixed

Android specific
iOS specific

Readme

Source

@react-native/gradle-plugin

Version

A Gradle Plugin used to support development of React Native applications for Android.

Installation

yarn add @react-native/gradle-plugin

Note: We're using yarn to install deps. Feel free to change commands to use npm 3+ and npx if you like

FAQs

Last updated on 30 Mar 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc