reselect-lens
v1.0.6
Published
Visibilty for reselect in redux devtools
Downloads
3
Maintainers
Readme
Reselect Lens
Visibility for Reselect in Redux DevTools.
Installation
npm install --save reselect-lens
Web example
import reselectLens from 'reselect-lens';
import store from './store';
import * as fooSelectors from './selectors/foo';
import * as barSelectors from './selectors/bar';
// Best not to run reselect-lens in production.
if (process.env.NODE_ENV === 'development') {
const allSelectors = {
...fooSelectors,
...barSelectors
};
reselectLens(store, allSelectors);
}
- Open Chrome Developer Tools.
- Select the 'Redux' tab.
- Locate the dropdown list for choosing a store (top right of the screen).
- Choose the store called 'reselect-lens'.
- You should now be able to view the values returned by your selectors.
React Native example
import reselectLens from 'reselect-lens';
import store from './store';
import * as fooSelectors from './selectors/foo';
import * as barSelectors from './selectors/bar';
// Best not to run reselect-lens in production.
if (__DEV__) {
const allSelectors = {
...fooSelectors,
...barSelectors
};
reselectLens(store, allSelectors);
}
- Open your React Native Debugger.
- Ensure that Redux DevTools is on.
- Locate the dropdown list for choosing a store (top right of the Redux DevTools panel).
- Choose the store called 'reselect-lens'.
- You should now be able to view the values returned by your selectors.