Parses ungrouped, Western-grouped or South Asian-grouped amounts.
One optional currency prefix OR suffix is allowed, with a leading minus
or enclosing parentheses for negatives. Returns an approximate JS number;
fractional digits are preserved without rounding, subject to Number precision.
Parameters
input: unknown
Amount as a number or text. Accepts Rs./LKR/රු./ரூ. before or after, Western or lakh grouping, and - or parentheses for negatives.
Returns number|null
The amount as a JavaScript number, or null if malformed. Use parseLKRMinorUnits for exact money.
Parses ungrouped, Western-grouped or South Asian-grouped amounts. One optional currency prefix OR suffix is allowed, with a leading minus or enclosing parentheses for negatives. Returns an approximate JS number; fractional digits are preserved without rounding, subject to Number precision.