You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to configure redux-persist-immutable, it fails with unexpected token o in json at position 1 which indicates to me that something is trying to parse an object as JSON. Tracing the code down, I found that redux-persist-transform-immutable/index.js is expecting JSON when it creates its transformers. I modified their code to transform raw into JSON right before it transforms it, and the error goes away; however, the data does not get autoRehydrated.
Here is how I've implemented redux-persist-immutable, right before I hand the store over to <Provider> I have more reducers, but I've trimmed it down for brevity.
this library should be able to handle both interchangeably. It may require an is immutable check on the top level and fallback to normal reconciliation. PR welcome!
When trying to configure redux-persist-immutable, it fails with
unexpected token o in json at position 1
which indicates to me that something is trying to parse an object as JSON. Tracing the code down, I found thatredux-persist-transform-immutable/index.js
is expecting JSON when it creates its transformers. I modified their code to transformraw
into JSON right before it transforms it, and the error goes away; however, the data does not get autoRehydrated.Here is how I've implemented redux-persist-immutable, right before I hand the store over to
<Provider>
I have more reducers, but I've trimmed it down for brevity.store.js
The text was updated successfully, but these errors were encountered: