mirror of
https://github.com/angular/angular
synced 2026-05-24 09:28:37 +00:00
It's perfectly valid for an abstract control not to have a defined parent; yet previously the types were asserting that AbstractControl#parent is not a null value. This changes correctly reflects the run-time behavior through the types. BREAKING CHANGE: Type of AbstractFormControl.parent now includes null `null` is now included in the types of .parent. If you don't already have a check for this case, the TypeScript compiler might compain. A v11 migration exists which adds the not-null assertion operator where necessary. In an unlikely case your code was testing the parnet against undefined with sitrct equality, you'll need to change this to `=== null` instead, since the parent is not explicily initialized with `null` instead of being left `undefined`. Fixes #16999 PR Close #32671 |
||
|---|---|---|
| .. | ||
| src | ||
| test | ||
| BUILD.bazel | ||
| index.ts | ||
| package.json | ||
| PACKAGE.md | ||
| public_api.ts | ||