until.ts 381 Bytes
export function moneyFormat (value: string) {
    if(value) {
        let numString = value.toString();
        let result = "";
        while (numString.length > 3) {
            result = "," + numString.slice(-3) + result;
            numString = numString.slice(0, numString.length - 3)
        }
        if (numString) {
            return numString + result
        }
    }
}