-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathindex.d.ts
67 lines (63 loc) · 1.95 KB
/
index.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
import { Reducer } from "redux"
export interface syncFirebaseOptions {
apiKey: string
store: any
projectId: string
databaseURL: string
bindings: any
name?: string
onCancel?: () => void
onAuth?: () => void
pathParams?: (state: any) => any
}
export interface syncFirebaseAPI {
unsubscribe(): void
addBinding: (binding: any) => void
removeBinding: (name: string) => void
updateBinding: (binding: any) => void
}
export function syncFirebase(options: syncFirebaseOptions): syncFirebaseAPI
export function firebaseToProps<T>(
firebaseBindings: Array<string>,
mapStateToProps?: (state: any, props: any) => T
): any
export function firebaseReducer(): Reducer<{}>
export interface WriteInterface {
method: string
path: string | Function
value: any
ownProps: any
}
export interface FirebaseActions {
updateConfig(options: any): any
addArrayChild(
path: string,
key: string,
value: any,
previousChildKey: string
): any
changeArrayChild(path: string, key: string, value: string): any
moveArrayChild(path: string, snapshot: any, previousChildKey: string): any
removeArrayChild(path: string, snapshot: any): any
updateArray(path: string, key: string, value: string[]): any
updateObject(path: string, snapshot: any): any
replaceValue(path: string, value: string): any
completeInitialFetch(): any
receiveInitialValue(path: string): any
connect(): any
authenticateUser(authData: any): any
unauthenticateUser(): any
passwordLogin(email: string, password: string): any
oAuthLogin(flowCode: string, providerCode: string, scopes: string[]): any
logout(): any
createUser(email: string, password: string): any
resetPassword(email: string): any
write(options: WriteInterface): any
clearLoginError(): any
clearRegistrationError(): any
clearResetPasswordError(): any
clearWriteErrors(path: string): any
revokePermissions(error: any): any
clearPermissionsError(): any
}
export const firebaseActions: FirebaseActions