Posted inStandard Objects: Date
How to create a date object in JavaScript
JavaScript's new Date(dateString) is unreliable and causes bugs due to browser-dependent parsing. For consistent results, use the ISO 8601 format (YYYY-MM-DD). For ambiguous strings, parse manually and use the multi-argument new Date(year, month, day) constructor to prevent issues.
