Closed longhoangwkm closed 2 years ago
Please don't link old issues. Issues are not the place to learn from.
There is a decimalPlaces method to round a BigNumber to a specified number of decimal places.
y = new BigNumber('1234567.898765');
y = y.decimalPlaces(2, BigNumber.ROUND_FLOOR);
y.toString(); // '1234567.89'
Please ask any further usage questions on a website like Stack Overflow.
Thanks
Hi, I checked solution from https://github.com/MikeMcl/bignumber.js/issues/69
But that is not solution what I looking for. I wanna floor without comma. Is there any way to do
Expected result:
1234567.89