can-define-stream-rxjs
v0.2.3
Published
Define properties with streams on can-define types.
Downloads
6
Maintainers
Readme
can-define-stream-rxjs
Define properties with streams on can-define types.
Syntax
canDefineStreamRxjs([DefineMap])
Example
var canDefineStreamRx = require('can-define-stream-rxjs');
var MyMap = DefineMap.extend({
foo: 'string',
bar: { type: 'string', value: 'bar' },
baz: {
type: 'string',
stream: function( stream ) {
var fooStream = this.stream('.foo');
var barStream = this.stream('.bar');
return stream.merge(fooStream).merge(barStream);
}
}
});
canDefineStreamRx(MyMap);
Testing
npm test