Files
angular__angular/packages
Leon Senft 44cd18c183 refactor(forms): remove a TODO and simplify update on <select> mutations
Remove an unnecessary TODO comment. The native `<select>` tracks its
`value` by keeping track of the selected `<option>`. Thus if the value
was set *before* the corresponding option is created, the `<select>`
will ignore it, but the framework doesn't know that and will cache the
bound value anyways. Therefore, checking if the value changed since it
was last bound when the mutation that creates the selected `<option>`
occurs would in fact prevent a needed update, leaving the `<select>` and
field values out of sync.

Furthermore, we know the control type is a native `<select>` element, so
we can update its value directly instead of going through
`updateNativeControl()` which would perform a redundant input type
check.
2025-11-10 07:47:58 -08:00
..
2025-11-06 10:03:05 -08:00
2025-11-06 10:03:05 -08:00
2025-11-06 10:03:05 -08:00
2025-11-06 10:03:05 -08:00
2025-11-06 10:03:05 -08:00
2025-11-06 10:03:05 -08:00
2025-11-06 10:03:05 -08:00
2025-11-06 10:03:05 -08:00
2025-11-06 10:03:05 -08:00
…
…
2025-11-06 10:03:05 -08:00

Angular

The sources for this package are in the main Angular repo. Please file issues and pull requests against that repo.

Usage information and reference details can be found in Angular documentation.

License: MIT