Step 1.2 - Break IDE store and router cyclical dependency
- Step 1.1 - Create modules to help break store and router cyclical dependency
- Step 1.2 - Break IDE store and router cyclical dependency
What does this MR do?
This MR breaks the cyclical dependency between the singleton Vuex store and the singleton VueRouter in the IDE.
How does it do this?
- The router module now exports a factory function which takes a reference to the store as a parameter.
- It uses the
sync_store_and_router
module which was introduced in !33787 (merged).
But why? Is this really necessary?
This cyclicaly dependency (besides causing some potentially non-deterministic scenarios) currently creates some difficulty with cleanly testing the FE integration of the IDE. Because of this dependency, the router dispatches actions on import which leaves side-effects and is hard to deal with...
References
- Related to #208800 (closed)
- Closes #28717 (closed)