redux-saga
Advanced tools
Comparing version 0.3.1 to 0.3.2
@@ -8,2 +8,5 @@ 'use strict'; | ||
exports.remove = remove; | ||
var _marked = [sampleGen].map(regeneratorRuntime.mark); | ||
var TASK = exports.TASK = Symbol('TASK'); | ||
@@ -19,2 +22,13 @@ var kTrue = exports.kTrue = function kTrue() { | ||
function sampleGen() { | ||
return regeneratorRuntime.wrap(function sampleGen$(_context) { | ||
while (1) switch (_context.prev = _context.next) { | ||
case 0: | ||
case 'end': | ||
return _context.stop(); | ||
} | ||
}, _marked[0], this); | ||
} | ||
var genConstructor = sampleGen.constructor; | ||
var is = exports.is = { | ||
@@ -32,3 +46,3 @@ undef: function undef(v) { | ||
generator: function generator(g) { | ||
return is.func(g) && g.constructor.name === 'GeneratorFunction'; | ||
return is.func(g) && g.constructor === genConstructor; | ||
}, | ||
@@ -35,0 +49,0 @@ iterator: function iterator(it) { |
{ | ||
"name": "redux-saga", | ||
"version": "0.3.1", | ||
"version": "0.3.2", | ||
"description": "Saga middleware for Redux to handle Side Effects", | ||
@@ -12,10 +12,18 @@ "main": "lib/index.js", | ||
"prepublish": "npm run check && npm run compile", | ||
"counter": "budo examples/counter/src/main.js:build.js --dir examples/counter --verbose --live -- -t babelify", | ||
"build-counter": "browserify --debug examples/counter/src/main.js -t babelify --outfile examples/counter/build.js", | ||
"test-counter": "babel-node examples/counter/test/sagas.js | tap-spec", | ||
"shop": "budo examples/shopping-cart/src/main.js:build.js --dir examples/shopping-cart --verbose --live -- -t babelify", | ||
"build-shop": "browserify --debug examples/shopping-cart/src/main.js -t babelify --outfile examples/shopping-cart/build.js", | ||
"test-shop": "babel-node examples/shopping-cart/test/sagas.js | tap-spec", | ||
"async": "budo examples/async/src/main.js:build.js --dir examples/async --verbose --live -- -t babelify", | ||
"build-async": "browserify --debug examples/async/src/main.js -t babelify --outfile examples/async/build.js", | ||
"build-examples": "npm run build-counter && npm run build-shop && npm run build-async", | ||
"test-examples": "npm run test-counter && npm run test-shop" | ||
"test-examples": "npm run test-counter && npm run test-shop", | ||
"real-world": "node examples/real-world/server.js" | ||
}, | ||
@@ -22,0 +30,0 @@ "repository": { |
@@ -41,3 +41,3 @@ An alternative Side Effect model for Redux applications. Instead of dispatching thunks | ||
- [Non blocking calls with fork/join](#non-blocking-calls-with-forkjoin) | ||
- [Building from sources](#building-from-sources) | ||
- [Building examples from sources](#building-examples-from-sources) | ||
@@ -517,4 +517,12 @@ #Getting started | ||
#Building from sources | ||
#Building examples from sources | ||
Pre-requisites | ||
- browserify | ||
- [budo](https://github.com/mattdesl/budo) to serve with live-reload `npm i -g budo` | ||
You can also build the examples manually, and open `index.html` at the root of each example | ||
directory to run. | ||
``` | ||
@@ -527,7 +535,10 @@ git clone https://github.com/yelouafi/redux-saga.git | ||
There are 3 examples ported from the Redux repos | ||
Below the examples ported (so far) from the Redux repos | ||
Counter example | ||
``` | ||
// build the example | ||
// run with live-reload server | ||
npm run counter | ||
// manual build | ||
npm run build-counter | ||
@@ -541,3 +552,6 @@ | ||
``` | ||
// build the example | ||
// run with live-reload server | ||
npm run shop | ||
// manual build | ||
npm run build-shop | ||
@@ -551,3 +565,6 @@ | ||
``` | ||
// build the example | ||
// run with live-reload server | ||
npm run async | ||
// manual build | ||
npm run build-async | ||
@@ -557,1 +574,7 @@ | ||
``` | ||
real-world example (with webpack hot reloading) | ||
``` | ||
cd examples/real-world | ||
npm start | ||
``` |
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
36946
374
575
0