Добавить
Уведомления

"Angular can waste your time" series. Pitfall #2 - ViewChild decorator returns 'undefined'

Say, you put a ref to input element in Angular template and want to create stream with input text updates with RxJS fromEvent function. For that you need input native element ref (click) which you can get with Angular ViewChild decorator: and if we try to run this code - it fails. Why? Watch the video to find out. Subscribe for email updates&news and get your free video-course on RxJS unit testing in Angular: https://mailchi.mp/9c8299ec62c2/rxjsunittesting Twitter: @El_extremal dev.to: dev.to/oleksandr medium: medium.com/@alexanderposhtaruk This video series will possibly become a part of my future video-course with advanced techniques of mastering Angular. Want to get a notification when it is done? Subcribe here: http://eepurl.com/gHF0av

Иконка канала Реактивные Задачи
29 подписчиков
12+
16 просмотров
2 года назад
12+
16 просмотров
2 года назад

Say, you put a ref to input element in Angular template and want to create stream with input text updates with RxJS fromEvent function. For that you need input native element ref (click) which you can get with Angular ViewChild decorator: and if we try to run this code - it fails. Why? Watch the video to find out. Subscribe for email updates&news and get your free video-course on RxJS unit testing in Angular: https://mailchi.mp/9c8299ec62c2/rxjsunittesting Twitter: @El_extremal dev.to: dev.to/oleksandr medium: medium.com/@alexanderposhtaruk This video series will possibly become a part of my future video-course with advanced techniques of mastering Angular. Want to get a notification when it is done? Subcribe here: http://eepurl.com/gHF0av

, чтобы оставлять комментарии