React Router V4 正式版发布,该版本相较于前面三个版本有根本性变化,遵循 Just Component 的 API 设计理念。

本次升级的主要变更有:

  • 声明式 Declarative

  • 可组合 Composability

本次升级 React Router V4 吸取了 React 的理念:所有的东西都是 Component。因此 升级之后的 Route、Link、Switch……等都是一个普通的组件。

React Router V4 基于 Lerna 管理多个 Repository。在此代码库包括:

  • react-router React Router 核心

  • react-router-dom 用于 DOM 绑定的 React Router

  • react-router-native 用于 React Native 的 React Router

  • react-router-redux React Router 和 Redux 的集成

  • react-router-config 静态路由配置帮助助手

React Router V4 中文文档 React Router github

React Router V4发布的更多相关文章

  1. [Web 前端] React Router v4 入坑指南

    cp from : https://www.jianshu.com/p/6a45e2dfc9d9 万恶的根源 距离React Router v4 正式发布也已经过去三个月了,这周把一个React的架子 ...

  2. [React Router v4] Intercept Route Changes

    If a user has entered some input, or the current Route is in a “dirty” state and we want to confirm ...

  3. [React Router v4] Redirect to Another Page

    Overriding a browser's current location without breaking the back button or causing an infinite redi ...

  4. [React Router v4] Render Multiple Components for the Same Route

    React Router v4 allows us to render Routes as components wherever we like in our components. This ca ...

  5. [React Router v4] Conditionally Render a Route with the Switch Component

    We often want to render a Route conditionally within our application. In React Router v4, the Route ...

  6. [React Router v4] Render Catch-All Routes with the Switch Component

    There are many cases where we will need a catch-all route in our web applications. This can include ...

  7. [React Router v4] Render Nested Routes

    With React Router v4 the entire library is built as a series of React components. That means that cr ...

  8. [React Router v4] Parse Query Parameters

    React Router v4 ignores query parameters entirely. That means that it is up to you to parse them so ...

  9. [React Router v4] Use Regular Expressions with Routes

    We can use regular expressions to more precisely define the paths to our routes in React Router v4. ...

随机推荐

  1. 基于Docker 搭建 wordpress

    在Docker中,一般遵循一个Docker只运行一个应用,这样方便维护. 首先需要将centos 镜像pull到本地,并搭建本地yum仓库 yum仓库地址:http://192.168.2.11:80 ...

  2. linux环境下,双击直连ping私有地址时候出现Destination host unreachable 解决办法

    在确保网线无故障的情况下,采取以下步骤 1.查看本机的hostname vim    /etc/sysconfig/network 2.编辑/etc/hosts vim /etc/hosts 加入以下 ...

  3. Django之模型ORM

    ORM介绍 ORM概念 对象关系映射(Object Relational Mapping,简称ORM)模式是一种为了解决面向对象与关系数据库存在的互不匹配的现象的技术. 简单的说,ORM是通过使用描述 ...

  4. eclispe启动进入子项目的解决

    问题描述: In Package Explorer I right-clicked on project and selected "Open in New Window". Ne ...

  5. crontab自动备份MySQL数据库并删除5天前备份

    1.创建备份文件夹 //备份数据库文件夹 mkdir /data/backmysql //crontab日志 mkdir /data/logs   2.创建脚本文件 db_user="xxx ...

  6. [thinkphp] 是如何输出一个页面的

    表面上看,TP输出一个页面很简单:$this->display(); 实际上是怎么回事呢?$this->display(); 这个display()方法是定义在ThinkPHP/Libra ...

  7. 洛谷——P1154 奶牛分厩

    P1154 奶牛分厩 题目描述 农夫约翰有N(1<=N<=5000)头奶牛,每头奶牛都有一个唯一的不同于其它奶牛的编号Si,所有的奶牛都睡在一个有K个厩的谷仓中,厩的编号为0到K-1.每头 ...

  8. RPD Volume 172 Issue 1-3 December 2016 评论03

    Using Stable Free Radicals to Obtain Unique and Clinically Useful Data In Vivo in Human Subjects Abs ...

  9. CentOS 7.1 中文正式版下载 - 最流行的免费开源企业级 Linux 服务器操作系统

    如果说 Ubuntu 是现今最受桌面用户欢迎的 Linux 操作系统,那么 CentOS 就是最受公司.企业.IDC 喜爱的 Linux 发行版了.得益于极为出色的稳定性,全球范围内无数著名网站均选用 ...

  10. Verify Preorder Serialization of a Binary Tree -- LeetCode

    One way to serialize a binary tree is to use pre-order traversal. When we encounter a non-null node, ...