I have a question about react-router: for example, I want to redirect from Create form to Edit form after called to create api (using redux-saga) successfully. How should I use react-router in this case?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
If you include also react-router-redux you can simply treat the page change as another redux action to call from saga (using the new push
API).
Something like...
yield put(push('your/route'))