Incrementing with adding digits “eats” the value after period
kizu opened this issue · comments
Look at the following example: if you'd have a value like 9.123em
and would increment it by one, you'd gain 10.12em
, so if you'd decrement it and increment again, you'd get 10.1em
and so on. The last digit after period become lost.
It looks like there is something rounded: if you'd increment 9.9
by one, you'd get 11
Confirmed, still present in v2 😢
It might be useful to use .toFixed(Math.max(valPrecision.decimals, offsetPrecision.decimals))
instead of .toPrecision
?