Shorten shortenNumber code

pull/194/head
Lim Chee Aun 2023-07-23 14:09:39 +08:00
rodzic 5fa02f9cc4
commit 4bf6b00b94
1 zmienionych plików z 4 dodań i 6 usunięć

Wyświetl plik

@ -1,7 +1,5 @@
const { locale } = Intl.NumberFormat().resolvedOptions();
export default function shortenNumber(num) {
return Intl.NumberFormat(locale, {
notation: 'compact',
}).format(num);
}
const shortenNumber = Intl.NumberFormat(locale, {
notation: 'compact',
}).format;
export default shortenNumber;