https://github.com/loreanvictor/rxmetics
Arithmetic(s) for RxJS observables
https://github.com/loreanvictor/rxmetics
arithmetics observables rxjs rxjs-observables
Last synced: 2 months ago
JSON representation
Arithmetic(s) for RxJS observables
- Host: GitHub
- URL: https://github.com/loreanvictor/rxmetics
- Owner: loreanvictor
- License: mit
- Created: 2020-05-02T14:17:40.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2023-03-04T16:37:24.000Z (about 2 years ago)
- Last Synced: 2025-03-18T02:44:45.652Z (2 months ago)
- Topics: arithmetics, observables, rxjs, rxjs-observables
- Language: TypeScript
- Homepage: https://loreanvictor.github.io/rxmetics
- Size: 1.14 MB
- Stars: 11
- Watchers: 4
- Forks: 1
- Open Issues: 18
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README

## _Arithmetics for RxJS observables._
[](https://travis-ci.org/loreanvictor/rxmetics)
[](https://codecov.io/gh/loreanvictor/rxmetics)
[](https://www.npmjs.com/package/rxmetics)
[](LICENSE)```bash
npm i rxmetics
```This is a minimal RxJS library for lazy people. Instead of this:
```ts
import { combineLatest, ... } from 'rxjs';
import { map, ... } from 'rxjs/operators';// ...
combineLatest(a, b).pipe(map(([a, b]) => a + b))...
```You can do this:
```ts
import { add } from 'rxmetics';// ...
add(a, b)...
```Or this:
```ts
import { add } from 'rxmetics/pipes';// ...
a.pipe(add(b))...
```But its not just for numbers (its RxJS arithmetic**s**):
```ts
import { and, eq } from 'rxmetics';// ...
and(a.pipe(eq(32)), b.pipe(eq('halo')))...
``````ts
import { rxl } from 'rxmetics';
import { interval } from 'rxjs';// ...
rxl`hellow ${interval(1000)}`.subscribe(console.log);
// RESULT:
// > hellow
// > hellow 1
// > hellow 2
// > hellow 3
// ...
```[Check out the docs](https://loreanvictor.github.io/rxmetics) for more info.