摘要: 高阶组件中的withRouter, 作用是将一个组件包裹进Route里面, 然后react-router的三个对象history, location, match就会被放进这个组件的props属性中. 1 import React from 'react' 2 import './nav.css' 阅读全文
posted @ 2020-03-09 12:11 我有头盔 阅读(570) 评论(0) 推荐(0) 编辑