You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm struggling with adding dynamic modules to the store in a certain place.
In my case, I'm adding modules where each module has specific GUID that is its id.
Here is the structure of my dynamic module. const modules = [{ id, reducerMap: { [id]: combineReducers(reducers) } }]
In this case everything works fine, modules are attached to the store.
But I wouldn't like to place every dynamic loaded module in the root of the store.
I would like to place them in the specific place in the store e.g. 'dynamicModules' key in the store.
So I tried to do that in this way: const modules = [{ id, reducerMap: { dynamicModules: combineReducers({ [id]: reducer }) } }]
But it isn't working, because library checks whether the same key already exists in the store, so it will add only the first dynamic module. So my question is - Is there a method where I can point in which place dynamic modules should be attached in the store?
The text was updated successfully, but these errors were encountered:
Hello,
I'm struggling with adding dynamic modules to the store in a certain place.
In my case, I'm adding modules where each module has specific GUID that is its id.
Here is the structure of my dynamic module.
const modules = [{ id, reducerMap: { [id]: combineReducers(reducers) } }]
In this case everything works fine, modules are attached to the store.
But I wouldn't like to place every dynamic loaded module in the root of the store.
I would like to place them in the specific place in the store e.g. 'dynamicModules' key in the store.
So I tried to do that in this way:
const modules = [{ id, reducerMap: { dynamicModules: combineReducers({ [id]: reducer }) } }]
But it isn't working, because library checks whether the same key already exists in the store, so it will add only the first dynamic module. So my question is - Is there a method where I can point in which place dynamic modules should be attached in the store?
The text was updated successfully, but these errors were encountered: