mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-15 12:51:30 -05:00
1. Make String.prototype.localeCompare's `locales` parameter optional, so `undefined` is allowed. 2. Declare the `locales` parameter as a `string | string[]` union instead of using overloads. Having separate overloads for `string` and `string[]` unnecessarily prevents passing a `string | string[]`. (These overloads predate the introduction of union types.)