mirror of
https://github.com/zhigang1992/react-native-firebase.git
synced 2026-05-04 20:11:33 +08:00
[typings] Continue work on flow
This commit is contained in:
@@ -5,11 +5,20 @@ import { NativeModules } from 'react-native';
|
||||
|
||||
import INTERNALS from '../../utils/internals';
|
||||
import { isIOS } from '../../utils';
|
||||
import ModuleBase from '../../utils/ModuleBase';
|
||||
import PACKAGE from '../../../package.json';
|
||||
|
||||
const FirebaseCoreModule = NativeModules.RNFirebase;
|
||||
|
||||
export default class RNFirebaseUtils {
|
||||
type GoogleApiAvailabilityType = {
|
||||
status: number,
|
||||
isAvailable: boolean,
|
||||
isUserResolvableError?: boolean,
|
||||
hasResolution?: boolean,
|
||||
error?: string
|
||||
}
|
||||
|
||||
export default class RNFirebaseUtils extends ModuleBase {
|
||||
static _NAMESPACE = 'utils';
|
||||
static _NATIVE_DISABLED = true;
|
||||
static _NATIVE_MODULE = 'RNFirebaseUtils';
|
||||
@@ -105,7 +114,7 @@ export default class RNFirebaseUtils {
|
||||
* @android
|
||||
* @param bool
|
||||
*/
|
||||
set errorOnMissingPlayServices(bool: Boolean) {
|
||||
set errorOnMissingPlayServices(bool: boolean) {
|
||||
INTERNALS.OPTIONS.errorOnMissingPlayServices = bool;
|
||||
}
|
||||
|
||||
@@ -114,7 +123,7 @@ export default class RNFirebaseUtils {
|
||||
* @android
|
||||
* @param bool
|
||||
*/
|
||||
set promptOnMissingPlayServices(bool: Boolean) {
|
||||
set promptOnMissingPlayServices(bool: boolean) {
|
||||
INTERNALS.OPTIONS.promptOnMissingPlayServices = bool;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user