[android] Support RN 0.47.0 breaking changes

This commit is contained in:
Chris Bianca 2017-08-03 08:54:10 +01:00
parent 989396131c
commit 4f24f17eb5
12 changed files with 24 additions and 19 deletions

View File

@ -38,7 +38,7 @@ public class RNFirebasePackage implements ReactPackage {
* listed here. Also listing a native module here doesn't imply that the JS implementation of it * listed here. Also listing a native module here doesn't imply that the JS implementation of it
* will be automatically included in the JS bundle. * will be automatically included in the JS bundle.
*/ */
@Override // TODO: Removed in 0.47.0. Here for backwards compatability
public List<Class<? extends JavaScriptModule>> createJSModules() { public List<Class<? extends JavaScriptModule>> createJSModules() {
return Collections.emptyList(); return Collections.emptyList();
} }

View File

@ -36,7 +36,7 @@ public class RNFirebaseAdMobPackage implements ReactPackage {
* listed here. Also listing a native module here doesn't imply that the JS implementation of it * listed here. Also listing a native module here doesn't imply that the JS implementation of it
* will be automatically included in the JS bundle. * will be automatically included in the JS bundle.
*/ */
@Override // TODO: Removed in 0.47.0. Here for backwards compatability
public List<Class<? extends JavaScriptModule>> createJSModules() { public List<Class<? extends JavaScriptModule>> createJSModules() {
return Collections.emptyList(); return Collections.emptyList();
} }

View File

@ -35,7 +35,7 @@ public class RNFirebaseAnalyticsPackage implements ReactPackage {
* listed here. Also listing a native module here doesn't imply that the JS implementation of it * listed here. Also listing a native module here doesn't imply that the JS implementation of it
* will be automatically included in the JS bundle. * will be automatically included in the JS bundle.
*/ */
@Override // TODO: Removed in 0.47.0. Here for backwards compatability
public List<Class<? extends JavaScriptModule>> createJSModules() { public List<Class<? extends JavaScriptModule>> createJSModules() {
return Collections.emptyList(); return Collections.emptyList();
} }

View File

@ -35,7 +35,7 @@ public class RNFirebaseAuthPackage implements ReactPackage {
* listed here. Also listing a native module here doesn't imply that the JS implementation of it * listed here. Also listing a native module here doesn't imply that the JS implementation of it
* will be automatically included in the JS bundle. * will be automatically included in the JS bundle.
*/ */
@Override // TODO: Removed in 0.47.0. Here for backwards compatability
public List<Class<? extends JavaScriptModule>> createJSModules() { public List<Class<? extends JavaScriptModule>> createJSModules() {
return Collections.emptyList(); return Collections.emptyList();
} }

View File

@ -35,7 +35,7 @@ public class RNFirebaseRemoteConfigPackage implements ReactPackage {
* listed here. Also listing a native module here doesn't imply that the JS implementation of it * listed here. Also listing a native module here doesn't imply that the JS implementation of it
* will be automatically included in the JS bundle. * will be automatically included in the JS bundle.
*/ */
@Override // TODO: Removed in 0.47.0. Here for backwards compatability
public List<Class<? extends JavaScriptModule>> createJSModules() { public List<Class<? extends JavaScriptModule>> createJSModules() {
return Collections.emptyList(); return Collections.emptyList();
} }

View File

@ -35,7 +35,7 @@ public class RNFirebaseCrashPackage implements ReactPackage {
* listed here. Also listing a native module here doesn't imply that the JS implementation of it * listed here. Also listing a native module here doesn't imply that the JS implementation of it
* will be automatically included in the JS bundle. * will be automatically included in the JS bundle.
*/ */
@Override // TODO: Removed in 0.47.0. Here for backwards compatability
public List<Class<? extends JavaScriptModule>> createJSModules() { public List<Class<? extends JavaScriptModule>> createJSModules() {
return Collections.emptyList(); return Collections.emptyList();
} }

View File

@ -35,7 +35,7 @@ public class RNFirebaseDatabasePackage implements ReactPackage {
* listed here. Also listing a native module here doesn't imply that the JS implementation of it * listed here. Also listing a native module here doesn't imply that the JS implementation of it
* will be automatically included in the JS bundle. * will be automatically included in the JS bundle.
*/ */
@Override // TODO: Removed in 0.47.0. Here for backwards compatability
public List<Class<? extends JavaScriptModule>> createJSModules() { public List<Class<? extends JavaScriptModule>> createJSModules() {
return Collections.emptyList(); return Collections.emptyList();
} }

View File

@ -35,7 +35,7 @@ public class RNFirebaseMessagingPackage implements ReactPackage {
* listed here. Also listing a native module here doesn't imply that the JS implementation of it * listed here. Also listing a native module here doesn't imply that the JS implementation of it
* will be automatically included in the JS bundle. * will be automatically included in the JS bundle.
*/ */
@Override // TODO: Removed in 0.47.0. Here for backwards compatability
public List<Class<? extends JavaScriptModule>> createJSModules() { public List<Class<? extends JavaScriptModule>> createJSModules() {
return Collections.emptyList(); return Collections.emptyList();
} }

View File

@ -35,7 +35,7 @@ public class RNFirebasePerformancePackage implements ReactPackage {
* listed here. Also listing a native module here doesn't imply that the JS implementation of it * listed here. Also listing a native module here doesn't imply that the JS implementation of it
* will be automatically included in the JS bundle. * will be automatically included in the JS bundle.
*/ */
@Override // TODO: Removed in 0.47.0. Here for backwards compatability
public List<Class<? extends JavaScriptModule>> createJSModules() { public List<Class<? extends JavaScriptModule>> createJSModules() {
return Collections.emptyList(); return Collections.emptyList();
} }

View File

@ -35,7 +35,7 @@ public class RNFirebaseStoragePackage implements ReactPackage {
* listed here. Also listing a native module here doesn't imply that the JS implementation of it * listed here. Also listing a native module here doesn't imply that the JS implementation of it
* will be automatically included in the JS bundle. * will be automatically included in the JS bundle.
*/ */
@Override // TODO: Removed in 0.47.0. Here for backwards compatability
public List<Class<? extends JavaScriptModule>> createJSModules() { public List<Class<? extends JavaScriptModule>> createJSModules() {
return Collections.emptyList(); return Collections.emptyList();
} }

View File

@ -32,30 +32,35 @@ All in all, RNFirebase provides much faster performance (~2x) over the web SDK a
## Supported Firebase Features ## Supported Firebase Features
> The Web SDK column indicates what modules from the Firebase Web SDK are usable within React Native. > The Web SDK column indicates what modules from the Firebase Web SDK are usable within React Native.
| Firebase Features | v1 | [v2](https://github.com/invertase/react-native-firebase/pull/130) | Web SDK | | Firebase Features | v1 | v2 | Web SDK |
| ---------------------- | :---: | :---: | :---: | | ---------------------- | :---: | :---: | :---: |
| AdMob | ❌ | ✅ | ❌ | | AdMob | ❌ | ✅ | ❌ |
| Analytics             | ✅ | ✅ | ❌ | | Analytics             | ✅ | ✅ | ❌ |
| App Indexing           | ❌ | ❌ | ❌ | | App Indexing           | ❌ | ❌ | ❌ |
| Authentication | ✅ | ✅ | ✅ | | Authentication | ✅ | ✅ | ✅ |
| Cloud Messaging | ✅ | ✅ | ❌ | | Cloud Messaging (FCM) | ✅ | ✅ | ❌ |
| Crash Reporting | ✅ | ✅ | ❌ | | Crash Reporting | ✅ | ✅ | ❌ |
| Dynamic Links | ❌ | ❌ | ❌ | | Dynamic Links | ❌ | ❌ | ❌ |
| Invites | ❌ | ❌ | ❌ | | Invites | ❌ | ❌ | ❌ |
| Performance Monitoring | ✅ | ✅ | ❌ | | Performance Monitoring | ✅ | ✅ | ❌ |
| Realtime Database | ✅ | ✅ | ✅ | | Realtime Database | ✅ | ✅ | ✅ |
| - Offline Persistance | ✅ | ✅ | ❌ | | - Offline Persistence | ✅ | ✅ | ❌ |
| - Transactions | ✅ | ✅ | ✅ | | - Transactions | ✅ | ✅ | ✅ |
| Remote Config | ✅ | ✅ | ❌ | | Remote Config | ✅ | ✅ | ❌ |
| Storage | ✅ | ✅ | ❌ | | Storage | ✅ | ✅ | ❌ |
--- ---
### Supported versions - Firebase / React Native ### Supported versions - React Native / Firebase
> The table below shows the minimum supported versions of the Firebase SDKs and React Native > The table below shows the supported version of `react-native-firebase` for different React Native versions
| | v1 | [v2](https://github.com/invertase/react-native-firebase/pull/130) | | v0.36 - v0.39 | v0.40 - v0.46 | v0.47 +
| ------------------------------- | :---: | :---: | :---: |
| react-native-firebase | 1.X.X | 2.X.X | 2.1.X |
> The table below shows the minimum supported versions of the Firebase SDKs for each version of `react-native-firebase`
| | v1 | v2 |
| ---------------------- | :---: | :---: | | ---------------------- | :---: | :---: |
| React Native | 0.36.0+ | 0.40.0 + |
| Firebase Android SDK | 10.2.0+ | 11.0.0 + | | Firebase Android SDK | 10.2.0+ | 11.0.0 + |
| Firebase iOS SDK | 3.15.0+ | 4.0.0 + | | Firebase iOS SDK | 3.15.0+ | 4.0.0 + |

View File

@ -70,7 +70,7 @@ pod 'Firebase/RemoteConfig'
pod 'Firebase/Storage' pod 'Firebase/Storage'
``` ```
If you are new to Cocoapods or do not already have React installed as a pod, then add Yoga and React to your `Podfile` as follows: If you do not already have React and Yoga installed as pods, then add Yoga and React to your `Podfile` as follows:
```ruby ```ruby
pod "Yoga", :path => "../node_modules/react-native/ReactCommon/yoga" pod "Yoga", :path => "../node_modules/react-native/ReactCommon/yoga"