money-and-precision-contracts
Money and precision contracts
In the browser, money is not a number: IEEE-754 doubles can't represent most decimal fractions,
so amounts drift and rounding disagrees across toFixed, Math.round, and Intl. Core rule —
compute and store in integer minor units or a decimal type, round once with an
explicit mode, and let Intl.NumberFormat touch the value only at the display edge.
For which locale format to show (digit grouping, currency symbol, 1,234.56 vs 1.234,56) use
i18n-copy-and-layout — it owns display formatting and notes Intl but does not own the math.
For the same "correct on a round-number/UTC dev box" trap in date/time values, see the sibling
value-correctness skill datetime-correctness. For the numeric field's validity lifecycle,
error, and submit state, use js-form-validation-contracts; this skill owns what the parsed
value means, not the field UI.