How to use the re-reselect.FlatMapCache function in re-reselect

To help you get started, we’ve selected a few re-reselect examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github redux-orm / redux-orm / src / redux.js View on Github external
function createSelectorFromSpec(spec) {
    if (spec instanceof MapSelectorSpec) {
        // eslint-disable-next-line no-underscore-dangle
        const parentSelector = createSelectorFromSpec(spec._parent);
        return spec.createResultFunc(parentSelector);
    }
    return createCachedSelector(
        spec.dependencies,
        spec.resultFunc
    )({
        keySelector: spec.keySelector,
        cacheObject: new FlatMapCache(),
        selectorCreator: createSelector, // eslint-disable-line no-use-before-define
    });
}

re-reselect

Enhance Reselect selectors with deeper memoization and cache management

MIT
Latest version published 4 months ago

Package Health Score

79 / 100
Full package analysis