redux-persist-transform-compress-encrypt
To persist a compressed and encrypted Redux store
The package creates a transformer for redux-persist. The transformer stringifies the inbound state, compresses it using lz-string
and encrypts the compressed string with AES.
Installation
npm install --save redux-persist-transform-compress-encrypt
Usage
const transformer = const reducer =
If the package encounters anything unexpected, it skips the transformation, called onError and returns the state as it received.
Config
Here are all the keys you can pass to createCompressEncryptor
.
Test
npm run test
Notes
This package is technically bundling the packages redux-persist-transform-compress
and redux-persist-transform-encrypt
into one. Personally, I could not get them to work together and found it easier to just create my own transform.