mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
ed5f558a6c
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/45113 ## Changelog: [iOS][Added] - Code-generate an optional base class to use for every NativeModule Extend RN Code-gen to generate a NativeModule base class for each ObjC Turbo Modules. Its usage is not mandatory now, but would become for future features to add A practial first step would be to migrate https://github.com/facebook/react-native/blob/main/packages/react-native/ReactCommon/react/nativemodule/core/platform/ios/ReactCommon/RCTTurboModule.h#L157-L160 from the `protocol` to the default `interface` and then provide a default implementation for it Reviewed By: RSNara Differential Revision: D58907395 fbshipit-source-id: a6b0ef97a5c7f5bb0c53a4cb6fd83d2e55306953
@react-native/codegen
Installation
yarn add --dev @react-native/codegen
Note: We're using yarn to install deps. Feel free to change commands to use npm 3+ and npx if you like
Testing
To run the tests in this package, run the following commands from the React Native root folder:
yarnto install the dependencies. You just need to run this onceyarn jest packages/react-native-codegen.