-
Notifications
You must be signed in to change notification settings - Fork 208
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplifies typings on
just-compare
(#480)
* Simplifies typings on `just-compare` * remove all the TS tests which are now fine
- Loading branch information
1 parent
64f923f
commit ee4d7cd
Showing
2 changed files
with
1 addition
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,3 @@ | ||
// Definitions by: Justy Robles <https://github.com/justyrobles> | ||
|
||
type Primitive = boolean | string | number | bigint | null | undefined; | ||
|
||
declare function compare<T extends Primitive>(value1: T, value2: T): boolean; | ||
|
||
declare function compare<T1 extends object, T2 extends object & T1>( | ||
value1: T1, | ||
value2: T2 | ||
): boolean; | ||
|
||
declare function compare<T1 extends object & T2, T2 extends object>( | ||
value1: T1, | ||
value2: T2 | ||
): boolean; | ||
declare function compare(value1: unknown, value2: unknown): boolean; | ||
|
||
export default compare; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters