1.6.0 • Published 7 years ago
@w11k/rx-utils v1.6.0
rx-utils
Utilities for RxJS
Patrons
❤️ theCodeCampus - Trainings for Angular and TypeScript
API Documentation
🗄 TypeDoc online API documentation
| Operator | Description |
|---|---|
| debounceIf | Debounce values on the stream if the predicate returns true |
TSLint rules
Installation
Adjust your tslint.json
{
"rulesDirectory": [
"node_modules/@w11k/rx-utils/dist/tslint_rules"
],
"rules": {
"w11k-rxjs-subscribe-takeuntil": true,
"w11k-rxjs-subscribe-in-subscribe": true
}
}Run tslint with type info
tslint -p tsconfig.json -t verboseRule descriptions
w11k-rxjs-subscribe-takeuntil
This rule triggers if Observable#subscribe() is called and then enforces that
.pipe()is called directly before.subscribe()- and that
takeUntil()is called as the last pipe operator
w11k-rxjs-subscribe-in-subscribe
This rule triggers if Observable#subscribe() is called inside of another Observable#subscribe() call, e.g.
import {of} from "rxjs";
of(1).subscribe(() => {
of(2).subscribe(); // <-- error
});