Skip to content
This repository has been archived by the owner on Oct 26, 2018. It is now read-only.

Commit

Permalink
Update ImmutableJS instructions (#363)
Browse files Browse the repository at this point in the history
Took me a while before I realized I needed to convert my Immutable object to a plain object for this to work, so this may help others
  • Loading branch information
ericrav authored and timdorr committed Apr 17, 2016
1 parent d789e95 commit 5075f34
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ For other kinds of events in your system, you can use middleware on your Redux s
When using a wrapper for your store's state, such as Immutable.js, you will need to change two things from the standard setup:

1. Provide your own reducer function that will receive actions of type `LOCATION_CHANGE` and return the payload merged into state.
2. Pass a selector to access the payload state via the `selectLocationState` option on `syncHistoryWithStore`.
2. Pass a selector to access the payload state and convert it to a JS object via the `selectLocationState` option on `syncHistoryWithStore`.

These two hooks will allow you to store the state that this library uses in whatever format or wrapper you would like.

Expand Down

0 comments on commit 5075f34

Please sign in to comment.