fix(CountTo): Fix displaying empty string when the value is 0 (#864)

This commit is contained in:
MARVIN 2021-07-05 22:45:13 +08:00 committed by GitHub
parent 5f1a6cdc59
commit 82eb72bbce
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -84,7 +84,7 @@
}
function formatNumber(num: number | string) {
if (!num) {
if (!num && num !== 0) {
return '';
}
const { decimals, decimal, separator, suffix, prefix } = props;