How to use the fluxible/addons.BaseStore function in fluxible

To help you get started, we’ve selected a few fluxible 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 gpbl / isomorphic500 / src / stores / RouteStore.js View on Github external
import Fluxible from "fluxible/addons";
import Actions from "../constants/Actions";

class RouteStore extends Fluxible.BaseStore {

  static storeName = "RouteStore"

  static handlers = {
    [Actions.CHANGE_ROUTE_SUCCESS]: "handleNavigate",
    [Actions.CHANGE_ROUTE_START]: "changeRoute",
    [Actions.STATUS_404]: "status404",
    [Actions.STATUS_500]: "status500"
  }

  constructor(dispatcher) {
    super(dispatcher);
    this.currentRoute = null;
    this.currentPageName = null;
    this.loading = false;
    this.err = null;