@common-stack/frontend-stack-react 4.0.1-alpha.43 → 4.0.1-alpha.47
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -14,10 +14,11 @@ interface IReduxStore<S = any> {
|
|
|
14
14
|
middleware?: Middleware[];
|
|
15
15
|
initialState?: any;
|
|
16
16
|
persistConfig?: PersistConfig<any>;
|
|
17
|
+
reduxConfig?: any;
|
|
17
18
|
}
|
|
18
19
|
/**
|
|
19
20
|
* Add any reducers required for this app dirctly in to
|
|
20
21
|
* `combineReducers`
|
|
21
22
|
*/
|
|
22
|
-
export declare const createReduxStore: ({ scope, isDebug, isDev, reducers, rootEpic, enhancers, epicMiddleware, preMiddleware, postMiddleware, middleware, initialState, persistConfig, }: IReduxStore<any>) => import("@reduxjs/toolkit").Store<any, import("@reduxjs/toolkit").UnknownAction, unknown>;
|
|
23
|
+
export declare const createReduxStore: ({ scope, isDebug, isDev, reducers, rootEpic, enhancers, epicMiddleware, preMiddleware, postMiddleware, middleware, initialState, persistConfig, reduxConfig, }: IReduxStore<any>) => import("@reduxjs/toolkit").Store<any, import("@reduxjs/toolkit").UnknownAction, unknown>;
|
|
23
24
|
export {};
|
|
@@ -4,12 +4,11 @@ import {combineReducers,configureStore}from'@reduxjs/toolkit';import {persistRed
|
|
|
4
4
|
/* eslint-disable @typescript-eslint/no-var-requires */
|
|
5
5
|
/* eslint-disable global-require */
|
|
6
6
|
/* eslint-disable no-underscore-dangle */
|
|
7
|
-
const REGISTER_CONTRIBUTIONS = 'contribution/REGISTER_CONTRIBUTIONS';
|
|
8
7
|
/**
|
|
9
8
|
* Add any reducers required for this app dirctly in to
|
|
10
9
|
* `combineReducers`
|
|
11
10
|
*/
|
|
12
|
-
const createReduxStore = ({ scope, isDebug, isDev, reducers, rootEpic, enhancers = [], epicMiddleware, preMiddleware = [], postMiddleware = [], middleware = [], initialState, persistConfig, }) => {
|
|
11
|
+
const createReduxStore = ({ scope, isDebug, isDev, reducers, rootEpic, enhancers = [], epicMiddleware, preMiddleware = [], postMiddleware = [], middleware = [], initialState, persistConfig, reduxConfig, }) => {
|
|
13
12
|
const isBrowser = scope === 'browser';
|
|
14
13
|
const isElectronMain = scope === 'ElectronMain';
|
|
15
14
|
const rootReducer = combineReducers(reducers);
|
|
@@ -28,7 +27,7 @@ const createReduxStore = ({ scope, isDebug, isDev, reducers, rootEpic, enhancers
|
|
|
28
27
|
reducer: persistedReducer,
|
|
29
28
|
middleware: (getDefaultMiddleware) => getDefaultMiddleware({
|
|
30
29
|
serializableCheck: {
|
|
31
|
-
ignoredActions: [FLUSH, REHYDRATE, PAUSE, PERSIST, PURGE, REGISTER,
|
|
30
|
+
ignoredActions: [FLUSH, REHYDRATE, PAUSE, PERSIST, PURGE, REGISTER, ...(reduxConfig?.ignoredActions || [])],
|
|
32
31
|
},
|
|
33
32
|
}).concat(...middlewares),
|
|
34
33
|
devTools: isDev || isDebug,
|
|
@@ -55,6 +55,7 @@ const createReduxStore = (apolloClient, services, container) => {
|
|
|
55
55
|
epicMiddleware: epicMiddlewareFunc(apolloClient, services, container),
|
|
56
56
|
rootEpic: rootEpic,
|
|
57
57
|
reducers,
|
|
58
|
+
reduxConfig: features.getReduxConfig(),
|
|
58
59
|
});
|
|
59
60
|
}
|
|
60
61
|
if (container.isBound('ReduxStore')) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@common-stack/frontend-stack-react",
|
|
3
|
-
"version": "4.0.1-alpha.
|
|
3
|
+
"version": "4.0.1-alpha.47",
|
|
4
4
|
"description": "Client Module for react app",
|
|
5
5
|
"homepage": "https://github.com/cdmbase/fullstack-pro#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"watch": "npm run build:lib:watch"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@common-stack/client-react": "4.0.1-alpha.
|
|
32
|
+
"@common-stack/client-react": "4.0.1-alpha.47",
|
|
33
33
|
"@common-stack/core": "4.0.1-alpha.31",
|
|
34
34
|
"i18next-fs-backend": "^2.3.1",
|
|
35
35
|
"i18next-http-backend": "^2.5.2",
|
|
@@ -52,5 +52,5 @@
|
|
|
52
52
|
"typescript": {
|
|
53
53
|
"definition": "lib/index.d.ts"
|
|
54
54
|
},
|
|
55
|
-
"gitHead": "
|
|
55
|
+
"gitHead": "df1b7718e4d36336a468c518b0fd13c3683f248e"
|
|
56
56
|
}
|