• Overview
@angular/core

numberAttribute

function

Transforms a value (typically a string) to a number. Intended to be used as a transform function of an input.

  
    function numberAttribute(  value: unknown,  fallbackValue?: number): number;
  
  

numberAttribute

number

Transforms a value (typically a string) to a number. Intended to be used as a transform function of an input.

@paramvalueunknown

Value to be transformed.

@paramfallbackValuenumber

Value to use if the provided value can't be parsed as a number.

@returnsnumber
Jump to details