From 76f14b4bd26d2ee0b93a3066e171c8bbce9e5b9f Mon Sep 17 00:00:00 2001 From: afc163 Date: Mon, 11 Apr 2016 11:16:31 +0800 Subject: [PATCH] Fix BreadCrumb IndexRoute support, close #1375 & #571 --- components/breadcrumb/index.jsx | 1 + 1 file changed, 1 insertion(+) diff --git a/components/breadcrumb/index.jsx b/components/breadcrumb/index.jsx index 593d8f3769..83dd1309f8 100644 --- a/components/breadcrumb/index.jsx +++ b/components/breadcrumb/index.jsx @@ -52,6 +52,7 @@ const Breadcrumb = React.createClass({ if (routes && routes.length > 0) { const paths = []; crumbs = routes.map((route, i) => { + route.path = route.path || ''; let path = route.path.replace(/^\//, ''); Object.keys(params).forEach(key => { path = path.replace(`:${key}`, params[key]);