RxJS Advanced

Architect, Compose, and Test

Background pattern
Angular Logo
RxJS Logo

Level.Advanced

Duration.2 days

Get ready to step up your RxJS skills to the next level! This workshop is targeted at developers who already feel familiar with the RxJS basics and want to take it a step further!

Based on real-world examples, we will explore, evaluate, and use advanced RxJS techniques to develop sustainable solutions for complex use cases. Push your knowledge to the upper reaches and improve your ability to effectively handle tricky issues with RxJS.

Agenda

  • RxJS Logo

    Deep-dive into RxJS primitives

    • Comparison of different subject types

    • Observable as reactive primitive

    • The reactive context

    • Create custom RxJS operators

  • Angular Logo

    Angular RxJS best practices

    • Build reactive state management systems with RxJS

    • Memory efficiency and RxJS

  • RxJS Logo

    The power of RxJS schedulers

    • Performance optimizations

    • Animations

    • Ergonomic background processes

  • RxJS Logo

    A quick wrap-up on RxJS versions 7 & 8

    • (Performance) improvements

    • Fixes

    • Future changes

  • Checkmark.

    Custom Operators

    • Limitations of using pipe

    • Leveraging the observable lifecycle hooks

    • Write a custom higher-order operator

  • Checkmark.

    Testing

    • The clutter of asynchronous tests

    • Testing with async helpers

    • Marble testing

  • Checkmark.

    Higher order composition

    • Understand higher order observables

    • Learn combination & flattening operators

    • Use “All” operators like mergeAll

    • Understand the power of groupBy

  • Checkmark.

    Multicasting

    • Subjects rewound

    • The misuse of share operators

    • Understanding RxJS7 connectable observables

Description

Maintainable error handling and resilient data streams are a difficult but essential part of every vital application. The way we shape our state and the derived data streams is admittedly a matter of deep architecture knowledge, but also it involves dealing with the low-level problems of multicasting and shared state.

In this session, we will come to understand how to solve those problems from the inside out, create our own operators that are beyond using the pipe method, and implement our learnings in a reusable way.

As one of my favorite parts, we will reverse engineer Observables to have a clear picture of their lifecycle hooks and get a handle on how to leverage all of them in code.

To ensure we are safe from regressions, different testing approaches should be employed. Therefore, we will take a closer look at those and implement marble tests to cover teardown logic and avoid memory leaks over tests.

Takeaways

  • Understanding RxJS on an expert level

  • Effectively handling errors across RxJS applications

  • Creating reusable custom operators beyond using pipe

  • Testing approaches protecting a code base against regressions

  • Marble testing with RxJS

  • Multicasting operators in RxJS7

  • Advanced error handling

  • Error-prone code encapsulation

  • A deep dive into Subjects

  • Multicasting with observables 

  • Understand combination & flattening Operators

  • Stateful reactive programming