import { createStore, combineReducers, applyMiddleware } from "redux";
import thunk from "redux-thunk";
import authReducer from "./auth";
import promiseReducer from "./promise";

const reducers = combineReducers({
  promise: promiseReducer,
  auth: authReducer,
});

const store = createStore(reducers, applyMiddleware(thunk));

// const unsubscribe1 = store.subscribe(() => console.log(store.getState()))

export default store;
