MCPcopy Index your code
hub / github.com/angular/angular / isEmpty

Function isEmpty

packages/forms/signals/src/api/rules/validation/util.ts:59–64  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

57 * Checks if the given value is considered empty. Empty values are: null, undefined, '', false, NaN.
58 */
59export function isEmpty(value: unknown): boolean {
60 if (typeof value === 'number') {
61 return isNaN(value);
62 }
63 return value === '' || value === false || value == null;
64}
65
66/**
67 * Normalizes validation errors (which can be a single error, an array of errors, or undefined)

Callers 6

requiredFunction · 0.90
minLengthFunction · 0.90
emailFunction · 0.90
maxLengthFunction · 0.90
patternFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…