react-router-dom v5@^4.0.0跳转

Others 2019-04-25 06:28:37 2019-04-25 06:28:37 2299 次浏览
import {withRouter} from 'react-router-dom'
search(){
        this.props.history.push("/?tag=query&txt="+this.state.txt)
    }