Skip to content

isNullishEmpty

Type guard detecting an EitherNullishEmpty.

Interactive example

Syntax

typescript
function isNullishEmpty<
	GenericInput extends unknown
>(
  input: GenericInput
): input is Extract<GenericInput, EitherNullishEmpty>;

Parameters

  • input: Either coming from the nullish helpers.

Return value

true if the wrapped value is null or undefined.

See also

Released under the MIT license.