@tecnavia/react-native-bridge (1.4.0)
Installation
@tecnavia:registry=
npm install @tecnavia/react-native-bridge@1.4.0
"@tecnavia/react-native-bridge": "1.4.0"
About this package
react-native-bridge
Getting started
$ npm install @tecnavia/react-native-bridge --save
Android
Structure
the purpose of the following classes is provide a different implementation of react native
- TaFragment is the most important class, it load react native application in fragment, we aren't using ReactFragment because is bugged, specially with ReactDelegate
- TaActivity and TaApplication add some functionalities to an Activity or to an Application, is useful but not mandatory
- TaProps manage build props and integrate it with props from intent
- TaReactFragmentDelegate override a ReactDelegate and return ReactRootView
- TaReflection provide all methods to work with reflection
IMPORTANT
first of all, react native has autolink feature but has a limitation, because doesn't work if a native module is a dependency of another module.
TaReactNative expose getHost() to initialize an instance of ReactNativeHost class.
The class must return a list of ReactPackage instances, these instances are make by reflection
and the name of that must be listed inside a files int the following format packages(_.*?)?\.txt
file under assets folder
For example we have a packages.txt with all native dependencies listed in a package.json
android/app/src/main/assets/packages.txt
and another packages_tecnavia_utils.txt with all native dependencies listen in its package.json
node_modules/@tecnavia/react-native-utils/android/src/main/assets/packages_tecnavia_utils.txt
Dependencies
Development Dependencies
ID | Version |
---|---|
@tecnavia/react-native-splash-screen | 3.3.0 |
@tecnavia/react-native-utils | 1.3.0 |
prop-types | ^15.7.2 |
react | ^16.9.0 |
react-native | ^0.61.5 |
react-native-builder-bob | ^0.29.0 |
Peer Dependencies
ID | Version |
---|---|
@react-native-community/push-notification-ios | * |
@tecnavia/react-native-splash-screen | * |
@tecnavia/react-native-utils | * |
prop-types | * |
react | * |
react-native | * |