@@ -51,18 +51,20 @@ export interface AddDocumentParams {
51
51
primaryKey ?: string
52
52
}
53
53
54
- export type FacetFilter = ( string | string [ ] ) [ ]
54
+ export type FacetFilter = Array < string | string [ ] >
55
55
56
56
export interface SearchParams < T > {
57
57
offset ?: number
58
58
limit ?: number
59
- attributesToRetrieve ?: Extract < keyof T , string > [ ] | Extract < keyof T , string >
59
+ attributesToRetrieve ?:
60
+ | Array < Extract < keyof T , string > >
61
+ | Extract < keyof T , string >
60
62
attributesToCrop ?:
61
- | ( Extract < keyof T , string > | '*' ) [ ]
63
+ | Array < Extract < keyof T , string > | '*' >
62
64
| ( Extract < keyof T , string > | '*' )
63
65
cropLength ?: number
64
66
attributesToHighlight ?:
65
- | ( Extract < keyof T , string > | '*' ) [ ]
67
+ | Array < Extract < keyof T , string > | '*' >
66
68
| ( Extract < keyof T , string > | '*' )
67
69
filters ?: string
68
70
facetFilters ?: string | FacetFilter | FacetFilter [ ]
@@ -114,7 +116,9 @@ export interface FieldFrequency {
114
116
export interface GetDocumentsParams < T > {
115
117
offset ?: number
116
118
limit ?: number
117
- attributesToRetrieve ?: Extract < keyof T , string > [ ] | Extract < keyof T , string >
119
+ attributesToRetrieve ?:
120
+ | Array < Extract < keyof T , string > >
121
+ | Extract < keyof T , string >
118
122
}
119
123
120
124
export type GetDocumentsResponse <
@@ -131,7 +135,7 @@ export type GetDocumentsResponse<
131
135
: Array < Document < T > >
132
136
133
137
export type DocumentLike = { [ Key in string ] ?: DocumentField }
134
- export interface DocumentArray extends Array < DocumentField > { }
138
+ export type DocumentArray = DocumentField [ ]
135
139
export type DocumentField =
136
140
| string
137
141
| number
0 commit comments