mirror of
https://github.com/solidtime-io/solidtime.git
synced 2026-08-15 03:32:15 +01:00
Enable npm workspaces and update dependencies
This commit is contained in:
@@ -14,8 +14,8 @@ export type NumberFormat =
|
||||
export function formatNumber(value: number, format?: string): string {
|
||||
// Convert to fixed 2 decimal places first
|
||||
const parts = value.toFixed(2).split('.');
|
||||
const wholePart = parts[0];
|
||||
const decimalPart = parts[1];
|
||||
const wholePart = parts[0] ?? '0';
|
||||
const decimalPart = parts[1] ?? '00';
|
||||
|
||||
// Format the whole number part based on the format
|
||||
let formattedWhole: string;
|
||||
|
||||
Reference in New Issue
Block a user