Skip to content

kakachake/mini-react-router

Repository files navigation

Mini React Router

从 0 到 1 实现的 react router 路由功能

实现的组件

  • Router
  • Route
  • Switch
  • Link

实现的 hooks

  • useLocation:获取 location 对象
  • useHistory:获取 history 对象
  • useListen:路由监听

高阶组件

  • withRouter 获取当前路由状态

About

从 0 到 1 实现的 react router 路由功能

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published