Skip to content

Commit

Permalink
Support getHash and getSearch selectors for immutables
Browse files Browse the repository at this point in the history
  • Loading branch information
supasate committed Jan 1, 2019
1 parent b7bc1ac commit 80363ae
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/immutable.js
Expand Up @@ -8,4 +8,4 @@ export { default as routerMiddleware } from "./middleware"

export const ConnectedRouter = /*#__PURE__*/ createConnectedRouter(immutableStructure)
export const connectRouter = /*#__PURE__*/ createConnectRouter(immutableStructure)
export const { getLocation, getAction, createMatchSelector } = /*#__PURE__*/ createSelectors(immutableStructure)
export const { getLocation, getAction, getHash, getSearch, createMatchSelector } = /*#__PURE__*/ createSelectors(immutableStructure)
2 changes: 1 addition & 1 deletion src/seamless-immutable.js
Expand Up @@ -8,4 +8,4 @@ export { default as routerMiddleware } from "./middleware"

export const ConnectedRouter = /*#__PURE__*/ createConnectedRouter(immutableStructure)
export const connectRouter = /*#__PURE__*/ createConnectRouter(immutableStructure)
export const { getLocation, getAction, createMatchSelector } = /*#__PURE__*/ createSelectors(immutableStructure)
export const { getLocation, getAction, getHash, getSearch, createMatchSelector } = /*#__PURE__*/ createSelectors(immutableStructure)
9 changes: 8 additions & 1 deletion src/selectors.js
Expand Up @@ -40,7 +40,14 @@ const createSelectors = (structure) => {
}
}

return {getLocation, getAction, getRouter, getSearch, getHash, createMatchSelector}
return {
getLocation,
getAction,
getRouter,
getSearch,
getHash,
createMatchSelector,
}
}

export default createSelectors

0 comments on commit 80363ae

Please sign in to comment.