Remove redundant generic usage for is.falsy
This also align the generic and parameter type of `is.falsy` with `assert.falsy`.
This commit is contained in:
parent
a614e9dfeb
commit
078d8a050f
1 changed files with 1 additions and 1 deletions
|
|
@ -294,7 +294,7 @@ is.urlString = (value: unknown): value is string => {
|
||||||
is.truthy = <T>(value: T | Falsy): value is T => Boolean(value); // eslint-disable-line unicorn/prefer-native-coercion-functions
|
is.truthy = <T>(value: T | Falsy): value is T => Boolean(value); // eslint-disable-line unicorn/prefer-native-coercion-functions
|
||||||
|
|
||||||
// Example: `is.falsy = (value: unknown): value is (not true | 0 | '' | undefined | null) => Boolean(value);`
|
// Example: `is.falsy = (value: unknown): value is (not true | 0 | '' | undefined | null) => Boolean(value);`
|
||||||
is.falsy = <T>(value: T | Falsy): value is Falsy => !value;
|
is.falsy = (value: unknown): value is Falsy => !value;
|
||||||
|
|
||||||
is.nan = (value: unknown) => Number.isNaN(value as number);
|
is.nan = (value: unknown) => Number.isNaN(value as number);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue