Skip to content

actions returns a error : not a function #2026

Answered by dbritto-dev
RaffDv asked this question in General
Discussion options

You must be logged in to vote

@RaffDv in a nutshell you are persisting actions too, in order to make it work you need to use partialize: ({ state }) => ({ state })

Note: persisting something requires to serialize and deserialize something. Basically JSON.stringify() as JSON.parse() most of time depending on your storage and you can't persist functions in nested objects

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@dbritto-dev
Comment options

Answer selected by RaffDv
@RaffDv
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants