Skip to content

Commit

Permalink
feat(api): add NumericArray and TypedArray types
Browse files Browse the repository at this point in the history
  • Loading branch information
postspectacular committed Aug 23, 2018
1 parent ecfcdcd commit 519394b
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions packages/api/src/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ export type FnAny<T> = (...xs: any[]) => T;
*/
export type Listener = (e: Event) => void;

export type NumericArray = number[] | TypedArray;

/**
* Lookup path for nested data structures.
*/
Expand Down Expand Up @@ -61,6 +63,17 @@ export type StatefulPredicate<T> = () => Predicate<T>;
*/
export type StatefulPredicate2<T> = () => Predicate2<T>;

export type TypedArray =
Float32Array |
Float64Array |
Int8Array |
Int16Array |
Int32Array |
Uint8Array |
Uint8ClampedArray |
Uint16Array |
Uint32Array;

/**
* Observer function for `IWatch` implementations.
*/
Expand Down

0 comments on commit 519394b

Please sign in to comment.