mirror of
https://github.com/Mastermindzh/react-starter-kit.git
synced 2025-08-23 17:44:52 +02:00
- Updated to React 18
- Updated for public release - Git was reset for privacy reasons
This commit is contained in:
17
src/app/store.ts
Normal file
17
src/app/store.ts
Normal file
@@ -0,0 +1,17 @@
|
||||
import { configureStore, ThunkAction, Action } from "@reduxjs/toolkit";
|
||||
import counterReducer from "../features/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>
|
||||
>;
|
Reference in New Issue
Block a user