aboutsummaryrefslogtreecommitdiffstats
path: root/packages/instant/src/redux/store.ts
blob: 01deb86904b73e14b7fc2f936cceffe866f157b7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
import * as _ from 'lodash';
import { createStore, Store as ReduxStore } from 'redux';
import { devToolsEnhancer } from 'redux-devtools-extension/developmentOnly';

import { reducer, State } from './reducer';

export type Store = ReduxStore<State>;

export const store = {
    create: (state: State): Store => {
        return createStore(reducer, state, devToolsEnhancer({}));
    },
};