plane icon indicating copy to clipboard operation
plane copied to clipboard

[refactor]: MobX store structure

Open aaryan610 opened this issue 2 years ago • 0 comments

This PR includes the new MobX store structure

Problem:

  1. Multiple sources of data led to data duplicacy and problems in updating/mutating data.
  2. De-structuring the data(MobX observables) at the very beginning of the component tree caused unnecessary component re-renders.

Solution:

  1. Created one root store to store data which acts as the only source of data for all the sub-stores, including-
    • Label root store with 2 sub-stores- project label store, and workspace label store.
    • Member root store with 2 sub-stores- project member store, and workspace member store.
  2. De-structuring the data at the last component of the tree to avoid unnecessary re-rendering.

Other improvements:

  1. Created a better folder structure for the stores.
  2. Created separate hooks for each store.

Backend

  • Removed the issue id structuring in the response.
  • Created user specific views for workspace, project, cycle, module.
  • Back migrated the workspace members, project members view props.
  • Issue relation workflow change.
  • Global Views moved to Project Views.
  • Payload of the api changed with fields and expand keys.

aaryan610 avatar Dec 22 '23 09:12 aaryan610