Tomas Trajan:
https://www.youtube.com/watch?v=sbIlz-yuxQI&t=2513s
Kevin Kreuzer:
https://www.youtube.com/watch?v=fAFKK8JnPkI
| function hasFailedValidation< | |
| T extends Record<string, string | boolean | number> | |
| >( | |
| formState: FormState<FieldValues>, | |
| fieldName: keyof T, | |
| onFail?: (status: boolean) => string | |
| ) { | |
| const { isSubmitted, dirtyFields, touchedFields, errors } = formState; | |
| console.log(errors); |
| id = input.required() | |
| todo = toSignal(toObservable(this.id).pipe( | |
| takeUntilDestroyed(), | |
| switchMap((id) => | |
| this.#flightsService.getTodos(id) | |
| ) | |
| )); |
| import { | |
| ChangeDetectionStrategy, | |
| Component, | |
| inject, | |
| signal, | |
| } from '@angular/core'; | |
| import { CommonModule } from '@angular/common'; | |
| import { RouterOutlet } from '@angular/router'; | |
| import { ColorsService } from './colors.service'; |