UNPKG

react-whole-barrels

Version:

- [x] Es6/7 - [x] react/react-router/dva - [x] less - [x] dev-server - [x] 模块热替换(HMR) - [x] sourcemap - [x] CSS代码分割 - [x] 代码分割(SplitChunksPlugin) - [x] 浏览器缓存 - [x] tree shaking - [x] DellPlugin - [x] PWA - [x] eslint - [x] stylelint

16 lines 350 B
import {routerRedux} from 'dva/router'; export default { namespace: 'login', state: { }, effects: { * goHome({payload},{put}){ const {username, password} = payload; if(username === 'admin' && password === '123'){ yield put(routerRedux.push(`home`)); } } }, reducers: { }, };