react脚手架umi中的路由跳转

react脚手架umi中的路由跳转

*//导入路由组件*
import { withRouter, routerRedux } from 'dva/router'
 go = () => {
    const { dispatch } = this.props
    *//跳转路由*
    dispatch(routerRedux.push({
      pathname: '/a/index'
    }))
  }

你可能感兴趣的:(react,react,reactjs)