O'Reilly logo

Mastering Reactive JavaScript by Erich de Souza Oliveira

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The fundamentals of RxJS

In Chapter 3, A World Full of Change - Reactive Extentions to the Rescue, we learned about observables and observers; these two objects are the most important part of functional reactive programming. Observables are objects with the capacity to listen to events occurring in an environment and they notify other objects of these events; the objects being notified are called observers and they have the capacity to react to the events propagated by an observable. They can listen for up to three events:

  • onNext(): Triggers when new data is propagated by an observable to this observer
  • onError(): Triggers when an error is propagated by an observable to this observer
  • onCompleted(): Triggers when the observable finishes without ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required