My modern Angular course: angularstart.com/
In this video, we investigate how to use custom directives, TypeScript generics, and ngTemplateContextGuard to add strong typing to the ng-templates in the generic table component from the last video.
Get weekly content and tips exclusive to my newsletter: mobirony.ck.page/4a331b9076
Learn Angular with Ionic: ionicstart.com
Previous video (ngTemplateOutlet): • ngTemplateOutlet is WA...
Source code (untyped): github.com/joshuamorony/ng-te...
Source code (typed): github.com/joshuamorony/ng-te...
Chau's PR: github.com/joshuamorony/ng-te...
Chau's RU-vid: / chautran
Chau's Twitter: / nartc1410
0:00 Introduction
1:26 What's wrong?
3:55 Removing magic strings
7:09 Using TypeScript Generics
13:34 Using Generics with Directives
16:37 Using ngTemplateContextGuard
21:18 Star syntax
23:03 Conclusion
#angular #typescript
- More tutorials: eliteionic.com
- Follow me on Twitter: / joshuamorony
30 июн 2024