-
Notifications
You must be signed in to change notification settings - Fork 2.1k
fromEvent not firing in V4.0.1 at least with angularjs & angular-material #957
Comments
So it's throwing an exception? Or the event is not firing? Could you build a simple jsbin/jsfiddle to reproduce the issue? |
The event is not firing at all. |
@paulpdaniels here is the codepen: |
I'm learning RxJs right now and I was pulling the 4.0.1 from cdn, and yes... the fromEvent is not firing any events, I'm using plain javascript ( Vanilla ). It took some hours to realize that the problem was the version of the library, and not the implementation... My baby step wasn't working at all.. It fires events only if you're using jQuery... |
I'm using Observable fromEvent inside a very simple directive with angularjs and angular material,
everything goes well with V.4.0.0, but when I update to v.4.0.1 it does not work any more.
This is the link function of the angular directive:
link = (scope: IExtendedScope, ele: ng.IAugmentedJQuery, attrs: IExtendedAttrs) => {
this.rx.Observable.fromEvent(ele[0], 'click')
// bla bla bla
.subscribe(
(res: any) => console.log(res),
(err: Error) => console.log(err),
() => console.log('completed'));
});
The text was updated successfully, but these errors were encountered: