1.0.8 • Published 4 years ago

rxify-class v1.0.8

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

rxify-class

NPM version Linux macOS Windows compatible

Build status Coverage status Dependency status Renovate enabled

Open in Gitpod

Decorates an existing class with methods supporting Rxjs. No more ugly callback functions :). In contrast to other modules you can wrap a whole class in one go, specifying the methods you want to decorate.

Install

# NPM
$ npm install rxify-class

# Yarn
$ yarn add rxify-class

Usage

Example with in-memory MongoDB:

const rxifyClass = require('rxify-class');

const MongoInMemory = rxifyClass(
  require('mongo-in-memory'),
  ['start', 'getConnection']
);

var mongoInMemory = new MongoInMemory(8000);
mongoInMemory.start().subscribe(config => {
  mongoInMemory.getConnection('test').subscribe(client => {
    ...
  });
});

License

Unless stated otherwise all works are:

Copyright © Sebastian Landwehr info@dword-design.de

and licensed under:

MIT License

1.0.8

4 years ago

1.0.7

4 years ago

1.0.6

4 years ago

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

5 years ago

0.1.6

5 years ago

0.1.5

5 years ago

0.1.4

6 years ago

0.1.3

6 years ago

0.1.2

6 years ago

0.1.1

6 years ago

0.1.0

6 years ago