reactjs - Could we compose different Redux applications to create a bigger one? -
i building redux application scope has changed have move app inside 1 it's redux application well.
this looks like:
<mainapp > <components /> <myapp props={myappprops} /> </mainapp>
the main problem found how deal property changes myapp's store.
so doubts are:
- is there proper way handle different redux apps?
- how split huge app can develop different parts independently?
what redux app in opinion?
redux data management solution application:
if have 2 sets of reducers created combinereducers()
rootreducerforapp = combinereducers({reducer1, reducer2, reducer3}); rootreducerforsomethingelse = combinereducers({r1, r2, ...});
you combine , have 1 reducer app
combindedrootreducer = combinereducers({ rootreducerforapp, rootreducerforsomethingelse })
then create single store
let store = createstore(combinedrootreducer)
now can use actions need both of semantically separated app-parts same place
Comments
Post a Comment