Skip to content

Update inputnumber.ts

LNAhri requested to merge master into ln-page

for InputNumber, for tabindex:

PrimeNG documentation (available at https://primeng.org/inputnumber) writes that the tabindex is of type number

opening the source code of inputnumber.d.ts, I see that the type is string

when I use it, the compiler generates the error "Type 'number' is not assignable to type "string" ngtsc(2322)

my code: <p-inputNumber [tabindex]="2*i+1" .... />

note that the same [tabindex]="2*i+1" works great for other PrimeNG components

My resolution: edit inputnumber.d.ts, and change the declaration (on line 20 in my version of it) to tabindex: number;

then my code compiles

Merge request reports

Loading