frontend/store/index.ts
2022-10-22 10:37:05 +03:00

17 lines
468 B
TypeScript

import {configureStore} from '@reduxjs/toolkit'
import nodesInputReducer from './reducers/nodesInputReducer';
import thunk from 'redux-thunk'
const store = configureStore({reducer: nodesInputReducer, middleware: getDefaultMiddleware =>
getDefaultMiddleware({
thunk: {
extraArgument: nodesInputReducer
}
})})
export default store;
export type RootType = ReturnType<typeof store.getState>;
export type AppDispatch = typeof store.dispatch