import { configureStore } from '@reduxjs/toolkit';
import userSlice from './user/slice';

import { useDispatch } from 'react-redux';

export const store = configureStore({
  reducer: {userSlice},
})

export type RootState = ReturnType<typeof store.getState>;

type AppDispatch = typeof store.dispatch;

// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types
export const useAppDispatch = () => useDispatch<AppDispatch>();