import {
  type Action,
  configureStore,
  type ThunkAction,
} from '@reduxjs/toolkit';

export const store = configureStore({
  reducer: {
    /* insert slices here */
  },
  devTools: true,
});

export type RootState = ReturnType<typeof store.getState>;
export type AppStore = typeof store;
export type AppDispatch = AppStore['dispatch'];
export type AppThunk<ThunkReturnType = void> = ThunkAction<
  ThunkReturnType,
  RootState,
  unknown,
  Action
>;
