mirror of
https://github.com/terribleplan/next.js.git
synced 2024-01-19 02:48:18 +00:00
Bugfix/redux saga 1 0 0 not ready (#6176)
This reverts the changes made in [this pr](https://github.com/zeit/next.js/pull/6109). `redux-saga: "1.0.0"` changed the way it handles it's queues. Because of that we're still having trouble to implement the synchronous side-effects flow in `next-redux-saga`. See [this discussion](https://github.com/bbortt/next-redux-saga/pull/1) for more information. Therefore I would feel more comfortable not to mislead users by giving them a non-working example in the main branch.
This commit is contained in:
parent
f4f3649de3
commit
cf31021e25
|
@ -8,18 +8,18 @@
|
||||||
"start": "next start"
|
"start": "next start"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"es6-promise": "4.2.5",
|
"es6-promise": "4.1.1",
|
||||||
"isomorphic-unfetch": "3.0.0",
|
"isomorphic-unfetch": "2.0.0",
|
||||||
"next": "latest",
|
"next": "latest",
|
||||||
"next-redux-saga": "3.0.0",
|
"next-redux-saga": "3.0.0",
|
||||||
"next-redux-wrapper": "2.1.0",
|
"next-redux-wrapper": "2.0.0",
|
||||||
"react": "^16.7.0",
|
"react": "^16.0.0",
|
||||||
"react-dom": "^16.7.0",
|
"react-dom": "^16.0.0",
|
||||||
"react-redux": "6.0.0",
|
"react-redux": "5.0.7",
|
||||||
"redux": "4.0.1",
|
"redux": "4.0.0",
|
||||||
"redux-saga": "1.0.0"
|
"redux-saga": "0.16.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"redux-devtools-extension": "2.13.7"
|
"redux-devtools-extension": "2.13.2"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
/* global fetch */
|
/* global fetch */
|
||||||
|
|
||||||
import { all, call, delay, put, take, takeLatest } from 'redux-saga/effects'
|
import { delay } from 'redux-saga'
|
||||||
|
import { all, call, put, take, takeLatest } from 'redux-saga/effects'
|
||||||
import es6promise from 'es6-promise'
|
import es6promise from 'es6-promise'
|
||||||
import 'isomorphic-unfetch'
|
import 'isomorphic-unfetch'
|
||||||
|
|
||||||
|
@ -12,7 +13,7 @@ function * runClockSaga () {
|
||||||
yield take(actionTypes.START_CLOCK)
|
yield take(actionTypes.START_CLOCK)
|
||||||
while (true) {
|
while (true) {
|
||||||
yield put(tickClock(false))
|
yield put(tickClock(false))
|
||||||
yield delay(1000)
|
yield call(delay, 1000)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue