storeon-observable
Advanced tools
Comparing version 0.0.1 to 0.1.0
19
index.js
@@ -1,6 +0,3 @@ | ||
var BehaviorSubject = require('rxjs').BehaviorSubject | ||
var Subject = require('rxjs').Subject | ||
var merge = require('rxjs').merge | ||
var switchMap = require('rxjs/operators').switchMap | ||
var filter = require('rxjs/operators').filter | ||
var operators = require('rxjs/operators') | ||
var rxjs = require('rxjs') | ||
@@ -11,3 +8,3 @@ function combineEpics (epics) { | ||
return merge.apply(null, epics.map(function (epic) { | ||
return rxjs.merge.apply(null, epics.map(function (epic) { | ||
return epic.apply(null, args) | ||
@@ -19,7 +16,7 @@ })) | ||
function createEpicMiddleware (epics) { | ||
var epic$ = new BehaviorSubject(epics) | ||
var epic$ = new rxjs.BehaviorSubject(epics) | ||
return function (store) { | ||
var action$ = new Subject() | ||
var state$ = new Subject() | ||
var action$ = new rxjs.Subject() | ||
var state$ = new rxjs.Subject() | ||
@@ -32,3 +29,3 @@ store.on('@dispatch', function (_, event) { | ||
var result$ = epic$.pipe(switchMap(function (epic) { | ||
var result$ = epic$.pipe(operators.switchMap(function (epic) { | ||
return epic(action$, state$) | ||
@@ -45,3 +42,3 @@ })) | ||
return function (source) { | ||
return source.pipe(filter(function (event) { | ||
return source.pipe(operators.filter(function (event) { | ||
return events.indexOf(event) !== -1 | ||
@@ -48,0 +45,0 @@ })) |
{ | ||
"name": "storeon-observable", | ||
"version": "0.0.1", | ||
"version": "0.1.0", | ||
"description": "RxJS based module for Storeon which allows to create async actions", | ||
"main": "index.js", | ||
"sideEffects": false, | ||
"repository": "git@github.com:distolma/storeon-observable.git", | ||
@@ -13,2 +15,5 @@ "author": "Dmytro Mostovyi <djmakaron2009@gmail.com>", | ||
}, | ||
"peerDependencies": { | ||
"rxjs": ">=6.0.0-beta.0 <7" | ||
}, | ||
"devDependencies": { | ||
@@ -35,2 +40,3 @@ "@logux/eslint-config": "^28.2.1", | ||
"size-limit": "^1.3.2", | ||
"storeon": "^0.8.3", | ||
"typescript": "^3.4.5" | ||
@@ -52,6 +58,3 @@ }, | ||
"path": "index.js", | ||
"limit": "250 B", | ||
"ignore": [ | ||
"rxjs" | ||
] | ||
"limit": "240 B" | ||
} | ||
@@ -64,7 +67,3 @@ ], | ||
} | ||
}, | ||
"dependencies": { | ||
"rxjs": "^6.5.2", | ||
"storeon": "^0.8.3" | ||
} | ||
} |
@@ -7,3 +7,3 @@ # Storeon Observable | ||
The size is only 250 bytes. It uses [Size Limit] to control size. | ||
The size is only 240 bytes. It uses [Size Limit] to control size. | ||
@@ -10,0 +10,0 @@ Read more about Storeon [article]. |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1
5498
22
38
- Removedrxjs@^6.5.2
- Removedstoreon@^0.8.3
- Removedstoreon@0.8.7(transitive)