mirror of
https://github.com/zhigang1992/react-native-firebase.git
synced 2026-04-30 21:22:40 +08:00
[typings] Continue work on flow
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
import Query from './query.js';
|
||||
import Snapshot from './snapshot';
|
||||
import Disconnect from './disconnect';
|
||||
import ReferenceBase from './../../utils/ReferenceBase';
|
||||
import ReferenceBase from '../../utils/ReferenceBase';
|
||||
|
||||
import {
|
||||
promiseOrCallback,
|
||||
@@ -15,10 +15,12 @@ import {
|
||||
tryJSONParse,
|
||||
tryJSONStringify,
|
||||
generatePushID,
|
||||
} from './../../utils';
|
||||
} from '../../utils';
|
||||
|
||||
import INTERNALS from '../../utils/internals';
|
||||
|
||||
import type { DatabaseModifier, FirebaseError } from '../../types';
|
||||
|
||||
// track all event registrations by path
|
||||
let listeners = 0;
|
||||
|
||||
@@ -35,6 +37,13 @@ const ReferenceEventTypes = {
|
||||
child_moved: 'child_moved',
|
||||
};
|
||||
|
||||
type DatabaseListener = {
|
||||
listenerId: number;
|
||||
eventName: string;
|
||||
successCallback: Function;
|
||||
failureCallback?: Function;
|
||||
}
|
||||
|
||||
/**
|
||||
* @typedef {String} ReferenceLocation - Path to location in the database, relative
|
||||
* to the root reference. Consists of a path where segments are separated by a
|
||||
|
||||
Reference in New Issue
Block a user