~/talk

Safer Forms with Strict Types

Talkat ng-conf 2022 · 2022-08-31..09-02· [angular, typescript]
links:none on file
slides:none on file

Angular v14 ships typed forms that push strict TypeScript through reactive forms: the library uses control types (not just value shapes), a non‑nullable option to avoid runtime nulls, and a new FormRecord for open keyed homogeneous groups. formBuilder gains a non‑nullable shortcut, dot get uses template literal types to parse string paths, and getRawValue preserves disabled fields. The feature is fully backwards compatible, an automatic migration runs on upgrade, and the implementation is proven by migration across Google codebases.

AI-written summary · about

  1. 0:00Typed forms in Angular
  2. 1:02Motivation for typed forms
  3. 2:47Key benefits
  4. 4:10Compile-time errors prevented
  5. 5:13Value vs control types
  6. 6:36Null values in controls
  7. 7:59Disabled and optional controls
  8. 9:04Optional keys in groups
  9. 10:27Open-ended groups
  10. 11:09Fallback to untyped
  11. 11:50Typed form arrays
  12. 12:11FormBuilder improvements
  13. 13:35Dot get with template types
  14. 15:20Future plans for safety
  15. 16:45Conclusion
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.