https://github.com/kanitsharma/yieldtask
Make your data.task monads yieldable in redux sagas
https://github.com/kanitsharma/yieldtask
functional-programming react redux redux-saga task-monads-yieldable
Last synced: 3 months ago
JSON representation
Make your data.task monads yieldable in redux sagas
- Host: GitHub
- URL: https://github.com/kanitsharma/yieldtask
- Owner: kanitsharma
- License: mit
- Created: 2018-04-23T21:18:38.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-07-27T15:25:07.000Z (over 7 years ago)
- Last Synced: 2025-08-13T03:59:52.935Z (3 months ago)
- Topics: functional-programming, react, redux, redux-saga, task-monads-yieldable
- Language: JavaScript
- Homepage:
- Size: 79.1 KB
- Stars: 0
- Watchers: 0
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# yieldTask
Make your data.task monads yieldable in redux sagas.
### Example
```javascript
import runTask from "yieldtask";
import Task from "data.task";
const testTask = x => Task.of(a).map(x => x + 10);
function* test() {
const a = yield runTask(testTask, 10); // a => 20
}
function* mySaga() {
yield takeLatest("EXAMPLE_ACTION", test);
}
```