From 12708bab827150d5ab63ac75cdec295803dd504c Mon Sep 17 00:00:00 2001 From: Jonny Buchanan Date: Tue, 6 Oct 2015 16:36:22 +0100 Subject: [PATCH] Add state support to match() --- modules/match.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/match.js b/modules/match.js index bb8fe6be0d..f0118502e2 100644 --- a/modules/match.js +++ b/modules/match.js @@ -18,6 +18,7 @@ const createHistory = useRoutes(useBasename(createMemoryHistory)) function match({ routes, location, + state, parseQueryString, stringifyQuery, basename @@ -36,7 +37,7 @@ function match({ // Allow match({ location: '/the/path', ... }) if (typeof location === 'string') - location = history.createLocation(location) + location = history.createLocation(location, state) history.match(location, function (error, redirectLocation, nextState) { callback(error, redirectLocation, nextState && { ...nextState, history })