githubEdit

getValueOfStep()

Returns the range value of the given `step`

Range.prototype.getValueOfStep()

The getValueOfStep() method returns the range value of the given step.

circle-exclamation
range.class.ts
public getValueOfStep(step: number): number | undefined {
  return step > 0 && step <= this.steps ? this.range[step - 1] : undefined;
}

Parameters

Step parameter of numberarrow-up-right type to retrieve the range value.

Return type

Returns

The return value is the range value of the given step within a range otherwise undefinedarrow-up-right.

Example usage

Last updated