redux-persist
redux-persist copied to clipboard
redux-persist/constants not found
Can't resolve 'redux-persist/constants'
in 'projects/proto12/node_modules/redux-persist-crosstab'
currently using these dependencies ` { "dependencies": { "react": "^16.4.2", "react-dom": "^16.4.2", "react-redux": "^5.0.4", "react-router": "^3.0.0", "redux": "^3.6.0", "redux-persist": "^5.10.0", "redux-persist-crosstab": "^3.7.0", "redux-thunk": "^2.2.0", } }
`
Looks like you can just reference the constants from the main import according to https://github.com/rt2zz/redux-persist/pull/554/files
So just replace
import { xxx } from 'redux-persist/constants';
with
import { xxx } from 'redux-persist';
Example vite config:
{
resolve: {
alias: {
"redux-persist/constants": "redux-persist",
}
}
}
Obviously not ideal.