File tree Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ export type ListHook = {
6
6
loading: boolean;
7
7
value: DataSnapshot[];
8
8
};
9
- export type ListKeysHook<T> = {
9
+ export type ListKeysHook = {
10
10
error?: Object;
11
11
loading: boolean;
12
12
value: string[];
@@ -28,7 +28,7 @@ export type ObjectValHook<T> = {
28
28
};
29
29
30
30
declare export function useList(query: Query): ListHook;
31
- declare export function useListKeys<T> (query: Query): ListKeysHook<T> ;
31
+ declare export function useListKeys(query: Query): ListKeysHook;
32
32
declare export function useListVals<T>(query: Query, keyField?: string): ListValsHook<T>;
33
33
declare export function useObject(query: Query): ObjectHook;
34
34
declare export function useObjectVal<T>(query: Query): ObjectValHook<T>;
Original file line number Diff line number Diff line change 1
1
export { default as useList , ListHook } from './useList' ;
2
+ export { default as useListKeys , ListKeysHook } from './useListKeys' ;
2
3
export { default as useListVals , ListValsHook } from './useListVals' ;
3
4
export { default as useObject , ObjectHook } from './useObject' ;
4
5
export { default as useObjectVal , ObjectValHook } from './useObjectVal' ;
Original file line number Diff line number Diff line change 1
1
import { database } from 'firebase' ;
2
2
import useList from './useList' ;
3
3
4
- export type ListKeysHook < T > = {
4
+ export type ListKeysHook = {
5
5
error ?: Object ;
6
6
loading : boolean ;
7
7
value : string [ ] ;
8
8
} ;
9
9
10
- export default < T > ( query : database . Query ) : ListKeysHook < T > => {
10
+ export default ( query : database . Query ) : ListKeysHook => {
11
11
const { error, loading, value } = useList ( query ) ;
12
+ // @ts -ignore
12
13
return {
13
14
error,
14
15
loading,
You can’t perform that action at this time.
0 commit comments