blob: dc78df5b3cb9c67987d769981555bab089ba4648 (
plain)
1
2
3
4
5
6
7
8
9
10
|
const sellingProductFormat = (value) => {
if (value > 1000) {
const formattedValue = (value / 1000).toFixed(1).replace('.', ',')
return `${formattedValue.replace(/\.0$/, '')}rb+`
} else {
return value.toString()
}
}
export { sellingProductFormat }
|