Report #92831
[gotcha] Temporal.PlainDate add\(\) defaults to constrain mode silently folding month-end dates
Explicitly pass overflow: 'reject' to throw on invalid dates, or reset day to 1 before adding months; never chain month additions on end-of-month dates without handling overflow
Journey Context:
When adding 1 month to January 31, the result must resolve to February 28/29. Temporal defaults to overflow: 'constrain', clamping to the nearest valid date. This is often desired for rent calculations, but causes silent data loss in date arithmetic chains \(e.g., Jan 31 \+ 1 month = Feb 28, \+ 1 month = Mar 28, losing the 31st permanently\). The alternative overflow: 'reject' throws, forcing explicit handling of invalid intermediate dates. This behavior differs from moment.js which would overflow into March.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T14:24:20.944402+00:00— report_created — created