~/talk

The Control Container and I

Talkat ng-conf 2020: Hardwired · 2020-04-01..04-03· [angular]
slides:none on file

A multi-step Angular loan form for an Animal Crossing demo runs into "formControlName must be used with a parent form group" when splitting steps across routes and nested components and the fix is to surface the parent form group via ControlContainer either by adding it to child viewProviders with useExisting: FormGroupDirective or by providing it on the parent and injecting the container in children to call controlContainer.control.get('field').valid so navigation disables until validity is satisfied.

AI-written summary · about

  1. 0:00Introduction and use case
  2. 2:52Implementing multi-step forms
  3. 6:23The problem with nested forms
  4. 7:50Using ControlContainer
  5. 10:44Programmatic form control
  6. 14:12Conclusion and resources
~/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.