@@ -14,7 +14,7 @@ interface ArraySliceMetaInfo {
14
14
* a connection object for use in GraphQL. It uses array offsets as pagination,
15
15
* so pagination will only work if the array is static.
16
16
*/
17
- export function connectionFromArray < T > (
17
+ export declare function connectionFromArray < T > (
18
18
data : ReadonlyArray < T > ,
19
19
args : ConnectionArguments ,
20
20
) : Connection < T > ;
@@ -23,7 +23,7 @@ export function connectionFromArray<T>(
23
23
* A version of `connectionFromArray` that takes a promised array, and returns a
24
24
* promised connection.
25
25
*/
26
- export function connectionFromPromisedArray < T > (
26
+ export declare function connectionFromPromisedArray < T > (
27
27
dataPromise : Promise < ReadonlyArray < T > > ,
28
28
args : ConnectionArguments ,
29
29
) : Promise < Connection < T > > ;
@@ -37,7 +37,7 @@ export function connectionFromPromisedArray<T>(
37
37
* to materialize the entire array, and instead wish pass in a slice of the
38
38
* total result large enough to cover the range specified in `args`.
39
39
*/
40
- export function connectionFromArraySlice < T > (
40
+ export declare function connectionFromArraySlice < T > (
41
41
arraySlice : ReadonlyArray < T > ,
42
42
args : ConnectionArguments ,
43
43
meta : ArraySliceMetaInfo ,
@@ -47,7 +47,7 @@ export function connectionFromArraySlice<T>(
47
47
* A version of `connectionFromArraySlice` that takes a promised array slice,
48
48
* and returns a promised connection.
49
49
*/
50
- export function connectionFromPromisedArraySlice < T > (
50
+ export declare function connectionFromPromisedArraySlice < T > (
51
51
dataPromise : Promise < ReadonlyArray < T > > ,
52
52
args : ConnectionArguments ,
53
53
arrayInfo : ArraySliceMetaInfo ,
@@ -56,17 +56,17 @@ export function connectionFromPromisedArraySlice<T>(
56
56
/**
57
57
* Creates the cursor string from an offset.
58
58
*/
59
- export function offsetToCursor ( offset : number ) : ConnectionCursor ;
59
+ export declare function offsetToCursor ( offset : number ) : ConnectionCursor ;
60
60
61
61
/**
62
62
* Extracts the offset from the cursor string.
63
63
*/
64
- export function cursorToOffset ( cursor : ConnectionCursor ) : number ;
64
+ export declare function cursorToOffset ( cursor : ConnectionCursor ) : number ;
65
65
66
66
/**
67
67
* Return the cursor associated with an object in an array.
68
68
*/
69
- export function cursorForObjectInConnection < T > (
69
+ export declare function cursorForObjectInConnection < T > (
70
70
data : ReadonlyArray < T > ,
71
71
object : T ,
72
72
) : ConnectionCursor | null ;
@@ -76,7 +76,7 @@ export function cursorForObjectInConnection<T>(
76
76
* to use; if the cursor contains a valid offset, that will be used,
77
77
* otherwise it will be the default.
78
78
*/
79
- export function getOffsetWithDefault (
79
+ export declare function getOffsetWithDefault (
80
80
cursor : ConnectionCursor | null | undefined ,
81
81
defaultOffset : number ,
82
82
) : number ;
0 commit comments