redux-first-history v4.6.0-beta.1 Release Notes

Release Date: 2020-02-02 // 4 months ago
    • 👌 support history v5.0.0
    • 👌 support react-router v6.0.0 (add listenObject: true options )
      🚀 https://github.com/ReactTraining/react-router/releases/tag/v6.0.0-alpha.1

      import { createReduxHistoryContext, reachify } from "redux-first-history";import { createWouterHook } from "redux-first-history/wouter";import { createBrowserHistory } from "history";const { createReduxHistory, routerMiddleware, routerReducer } = createReduxHistoryContext({ history: createBrowserHistory(), listenObject: true, // support react-router v6.0 });export const history = createReduxHistory(store);export const reachHistory = reachify(history);export const wouterUseLocation = createWouterHook(history);


Previous changes from v4.5.0

    • 👌 support imperatively navigate from @reach/routerimport { navigate } from '@reach/router'`

    usage:

    import { createBrowserHistory } from 'history';import { globalHistory } from '@reach/router';const { createReduxHistory, routerMiddleware, routerReducer } = createReduxHistoryContext({ history: createBrowserHistory(), //others options if needed reachGlobalHistory: globalHistory });