0

I am using react-intl for formatting number based on locale.

For cs locale, this.props.intl.formatNumber(-0.0001) is returning -0. I want library to return -0,0001. So, i don't want to round number.

How can i achieve this.

mukesh210
  • 2,792
  • 2
  • 19
  • 41

1 Answers1

1

you need to specify minimumFractionDigits: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat

Long Ho
  • 599
  • 4
  • 15