⚠️ Mixin UI is currently in alpha stage
Documentation
Customization
Utils

Operators

Custom RxJS operators that provide declarative access to browser APIs and framework environment features. These operators allow you to compose and transform data streams while working with browser and Angular functionality in a reactive way.

Examples

Router API

Creates an observable that emits specific Angular Router events of the provided type:

import { NavigationEnd } from '@angular/router';
import { fromRouterEvent } from '@mixin-ui/cdk';

const navigationEnd = fromRouterEvent(NavigationEnd);

navigationEnd.subscribe(console.log);
// Results in:
// A NavigationEnd event object logged to the console every time
// the Angular Router emits a NavigationEnd event during navigation.

Render API

Creates an Observable that emits and completes next time the application finishes rendering. This operator utilizes Angular's afterNextRender api:

import { fromAfterNextRender } from '@mixin-ui/cdk';

const afterNextRender = fromAfterNextRender();

afterNextRender.subscribe(console.log);