Record Redux actions in Raygun
This commit is contained in:
parent
df73be6a91
commit
fd20a5e925
1 changed files with 9 additions and 1 deletions
10
src/store.ts
10
src/store.ts
|
@ -1,5 +1,6 @@
|
||||||
import rootReducer, { RootState } from "./rootReducer";
|
import raygun from "raygun4js"
|
||||||
import { configureStore, Action, getDefaultMiddleware } from "@reduxjs/toolkit";
|
import { configureStore, Action, getDefaultMiddleware } from "@reduxjs/toolkit";
|
||||||
|
import rootReducer, { RootState } from "./rootReducer";
|
||||||
import { ThunkAction } from "redux-thunk";
|
import { ThunkAction } from "redux-thunk";
|
||||||
import {
|
import {
|
||||||
mixerMiddleware,
|
mixerMiddleware,
|
||||||
|
@ -12,6 +13,13 @@ const store = configureStore({
|
||||||
middleware: [
|
middleware: [
|
||||||
mixerMiddleware,
|
mixerMiddleware,
|
||||||
mixerKeyboardShortcutsMiddleware,
|
mixerKeyboardShortcutsMiddleware,
|
||||||
|
store => next => action => {
|
||||||
|
raygun("recordBreadcrumb",
|
||||||
|
"redux-action",
|
||||||
|
action
|
||||||
|
);
|
||||||
|
return next(action);
|
||||||
|
},
|
||||||
...getDefaultMiddleware(),
|
...getDefaultMiddleware(),
|
||||||
],
|
],
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue