diff options
Diffstat (limited to 'frontend')
-rw-r--r-- | frontend/package.json | 2 | ||||
-rw-r--r-- | frontend/src/routes.js | 13 | ||||
-rw-r--r-- | frontend/yarn.lock | 6 |
3 files changed, 7 insertions, 14 deletions
diff --git a/frontend/package.json b/frontend/package.json index 6151c09b..35afa4a9 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -18,7 +18,7 @@ "redux": "^3.6.0", "redux-immutable": "^3.0.10", "redux-saga": "^0.14.3", - "redux-saga-router": "^1.1.0", + "redux-saga-router": "^2.0.0", "reflexbox": "^2.2.3", "reselect": "^2.5.4", "sockjs-client": "latest", diff --git a/frontend/src/routes.js b/frontend/src/routes.js index c0adcde5..70762aa2 100644 --- a/frontend/src/routes.js +++ b/frontend/src/routes.js @@ -1,20 +1,13 @@ -import { fork, take, cancel } from 'redux-saga/effects' +import { fork } from 'redux-saga/effects' import usernameChoiceSaga from './sagas/usernameChoice' import gameBrowserSaga from './sagas/gameBrowser' -import { LOCATION_CHANGE } from 'react-router-redux' export const makeSagaRoutes = wsConnection => ({ *'/'() { - const saga = yield fork(usernameChoiceSaga, wsConnection) - yield take(LOCATION_CHANGE) - yield cancel(saga) - yield console.log('canceled home') + yield fork(usernameChoiceSaga, wsConnection) }, *'/games'() { - const saga = yield fork(gameBrowserSaga, wsConnection) - yield take(LOCATION_CHANGE) - yield cancel(saga) - yield console.log('canceled games') + yield fork(gameBrowserSaga, wsConnection) } }) diff --git a/frontend/yarn.lock b/frontend/yarn.lock index a7556445..fd6457c5 100644 --- a/frontend/yarn.lock +++ b/frontend/yarn.lock @@ -4435,9 +4435,9 @@ redux-saga: version "0.13.0" resolved "https://registry.yarnpkg.com/redux-saga/-/redux-saga-0.13.0.tgz#9294386550deb0d56bc9a1b3c90a613e7ddb6593" -redux-saga-router@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/redux-saga-router/-/redux-saga-router-1.1.0.tgz#c2edf4445c9def382fd64d3e8f63c7f4d519bb91" +redux-saga-router@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/redux-saga-router/-/redux-saga-router-2.0.0.tgz#48d4622029347fce004ffa4f8c421a3a453050ae" dependencies: fsm-iterator "^1.0.0" history "^4.3.0" |