format library

Pakistani Rupee and lakh/crore formatting.

Same as the pakdatakit/format entry point of the npm package.

Functions

formatLakh(num amount) → String
Formats an amount using Pakistani lakh/crore conventions.
formatPKR(num amount) → String
Formats an amount as Pakistani Rupees with comma separators, rounded to whole rupees: "Rs. 150,000". Negative amounts are prefixed with - ("-Rs. 500").