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

Function booleanAttribute

packages/core/src/util/coercion.ts:23–25  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

21 * @publicApi
22 */
23export function booleanAttribute(value: unknown): boolean {
24 return typeof value === 'boolean' ? value : value != null && value !== 'false';
25}
26
27/**
28 * Transforms a value (typically a string) to a number.

Callers 3

coercion_spec.tsFile · 0.90
_updateDisabledMethod · 0.90
booleanOrUrlAttributeFunction · 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…