react-gauge-chart
react-gauge-chart copied to clipboard
Remove the rounding when formatTextValue callback is set
I think the the floatNumber
should not be called at https://github.com/Martin36/react-gauge-chart/blob/de1bba51848f50556663e64a9af9c2546bfe6dea/src/lib/GaugeChart/index.js#L442 and leave the option to the user to round it however he wants with formatTextValue
.
I agree. I'm working on cleaning this project up and will change this to accept original value. I would prefer to change formatTextValue
property to text
property that accepts string value instead of function as you should already have percentage value you've passed to the component available. I myself am showing the raw value with units before converted to percentage so the function is even more useless to me. Thoughts @Martin36 ?
I agree. I'm working on cleaning this project up and will change this to accept original value. I would prefer to change
formatTextValue
property totext
property that accepts string value instead of function as you should already have percentage value you've passed to the component available. I myself am showing the raw value with units before converted to percentage so the function is even more useless to me. Thoughts @Martin36 ?
I think that sounds great