UNPKG

strapi-plugin-ctrip-apollo

Version:

This is the plugin using for ctrip apollo to manager strapi application configuration.

34 lines (26 loc) 698 B
import { createSelector } from 'reselect'; import pluginId from '../../pluginId'; /** * Direct selector to the homePage state domain */ const selectHomePageDomain = () => state => state.get(`${pluginId}_homePage`); /** * Default selector used by HomePage */ const selectHomePage = () => createSelector( selectHomePageDomain(), (substate) => substate.toJS(), ); const makeSelectParams = () => createSelector( selectHomePageDomain(), (substate) => substate.get('params').toJS(), ); const makeSelectSearch = () => createSelector( selectHomePageDomain(), (substate) => substate.get('search'), ); export default selectHomePage; export { makeSelectSearch, makeSelectParams, };