mirror of
https://github.com/Mastermindzh/react-starter-kit.git
synced 2025-08-23 09:35:01 +02:00
18 lines
462 B
TypeScript
18 lines
462 B
TypeScript
import { configureStore, ThunkAction, Action } from "@reduxjs/toolkit";
|
|
import counterReducer from "../features/examples/counter/state/counterSlice";
|
|
|
|
export const store = configureStore({
|
|
reducer: {
|
|
counter: counterReducer,
|
|
},
|
|
});
|
|
|
|
export type AppDispatch = typeof store.dispatch;
|
|
export type RootState = ReturnType<typeof store.getState>;
|
|
export type AppThunk<ReturnType = void> = ThunkAction<
|
|
ReturnType,
|
|
RootState,
|
|
unknown,
|
|
Action<string>
|
|
>;
|