Skip to content

Commit e0a4bec

Browse files
chore(internal): add aliases for Record and Array (#735)
1 parent cae4f77 commit e0a4bec

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

src/core.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,20 @@ export {
3434

3535
export type Fetch = (url: RequestInfo, init?: RequestInit) => Promise<Response>;
3636

37+
/**
38+
* An alias to the builtin `Array` type so we can
39+
* easily alias it in import statements if there are name clashes.
40+
*/
41+
type _Array<T> = Array<T>;
42+
43+
/**
44+
* An alias to the builtin `Record` type so we can
45+
* easily alias it in import statements if there are name clashes.
46+
*/
47+
type _Record<K extends keyof any, T> = Record<K, T>;
48+
49+
export type { _Array as Array, _Record as Record };
50+
3751
type PromiseOrValue<T> = T | Promise<T>;
3852

3953
type APIResponseProps = {

0 commit comments

Comments
 (0)