If you say it
Big(9007199254740995)
you do not give the bignum library a chance! Your number literal is first parsed by pure JS, in which that number is not exactly representable. You can see it simply with
window.alert(9007199254740995);
which alerts 9007199254740996
.
In order for your selected signal library to successfully represent this number, you need to pass it as a string , for example:
Big('9007199254740995')
should get you that exact number like bignum.
source share