Skip to content

Commit 86bc612

Browse files
committed
[types] improve types
1 parent 34579df commit 86bc612

File tree

1 file changed

+5
-14
lines changed

1 file changed

+5
-14
lines changed

index.d.ts

Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
import type { TypedArray } from 'is-typed-array';
2+
13
/**
24
* Determines the type of the given collection, or returns false.
35
*
@@ -19,7 +21,7 @@ declare function whichTypedArray(value: whichTypedArray.TypedArray): whichTypedA
1921
declare function whichTypedArray(value: unknown): false | null;
2022

2123
declare namespace whichTypedArray {
22-
type TypedArrayName =
24+
export type TypedArrayName =
2325
| 'Int8Array'
2426
| 'Uint8Array'
2527
| 'Uint8ClampedArray'
@@ -32,20 +34,9 @@ declare namespace whichTypedArray {
3234
| 'BigInt64Array'
3335
| 'BigUint64Array';
3436

35-
type TypedArray =
36-
| Int8Array
37-
| Uint8Array
38-
| Uint8ClampedArray
39-
| Int16Array
40-
| Uint16Array
41-
| Int32Array
42-
| Uint32Array
43-
| Float32Array
44-
| Float64Array
45-
| BigInt64Array
46-
| BigUint64Array;
37+
export type { TypedArray };
4738

48-
type TypedArrayConstructor =
39+
export type TypedArrayConstructor =
4940
| Int8ArrayConstructor
5041
| Uint8ArrayConstructor
5142
| Uint8ClampedArrayConstructor

0 commit comments

Comments
 (0)