Skip to content

Instantly share code, notes, and snippets.

@ohager
Created May 15, 2017 16:50
Show Gist options
  • Select an option

  • Save ohager/e07b481a806f177d67bf19c09c562ed0 to your computer and use it in GitHub Desktop.

Select an option

Save ohager/e07b481a806f177d67bf19c09c562ed0 to your computer and use it in GitHub Desktop.
Composition Example
import {createStore, composeStoreActionHandler} from "../StoreFactory";
import ItemListActionHandler from "./actionHandler/ItemListActionHandler";
import ItemActionHandler from "./actionHandler/ItemActionHandler";
import UserActionHandler from "./actionHandler/UserActionHandler";
const actionHandler = composeStoreActionHandler(
ItemListActionHandler,
ItemActionHandler,
UserActionHandler
);
export default createStore( actionHandler );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment