new Intl.NumberFormat('en-IN', { maximumFractionDigits: 2 }).format(-4.125)
This returns -4.13, whilst round(-4.125, 2)
returns the correct value of -4.12, rounded towards the higher value, closer to 0
new Intl.NumberFormat('en-IN', { maximumFractionDigits: 2 }).format(-4.125)
This returns -4.13, whilst round(-4.125, 2)
returns the correct value of -4.12, rounded towards the higher value, closer to 0