Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Refactor] split rootstore #792

Closed
yuvalbl opened this issue Oct 13, 2021 · 0 comments
Closed

[Refactor] split rootstore #792

yuvalbl opened this issue Oct 13, 2021 · 0 comments
Assignees
Labels
blocked Priority 2 Priority 2 Technical Debt Code that should be rewritten differently
Milestone

Comments

@yuvalbl
Copy link
Collaborator

yuvalbl commented Oct 13, 2021

Blocked by #843

See combining-multiple-stores

Root store is too big, we should split it as follows (store + fields):

userStore (userStore.tsx):

  • isUserAuthenticated
  • userApiError
  • userInfo

newsFlashStore (newsFlashStore.tsx):

  • activeNewsFlashId
  • newsFlashFetchOffSet
  • newsFlashActiveFilter
  • newsFlashLoading

widgetStore (widgetStore.tsx) :

  • newsFlashWidgetsMeta (rename to widgetsMeta)
  • newsFlashWidgetsData (rename to widgetsData)
  • widgetBoxLoading (rename to widgetsLoading)

move language properties (like currentLanguageRouteString and selectedLanguage) to settingStore:

IMPORTANT:
after done splitting, make sure you remove the /* eslint-disable*/ comment from the root store, to allow linter to scan this file as well.

@yuvalbl yuvalbl added this to the v0.11.0 milestone Oct 13, 2021
@yuvalbl yuvalbl added blocking Priority 2 Priority 2 and removed blocking labels Oct 13, 2021
@yuvalbl yuvalbl modified the milestones: v0.11.0, v0.12.0 Dec 1, 2021
@yuvalbl yuvalbl added the Technical Debt Code that should be rewritten differently label Dec 29, 2021
@yuvalbl yuvalbl modified the milestones: v0.12.0, v0.13.0 Dec 29, 2021
@danielsh28 danielsh28 modified the milestones: v0.13.0, v0.14.0 Feb 8, 2022
@danielsh28 danielsh28 modified the milestones: v0.14.0, v0.15.0 Mar 6, 2022
@danielsh28 danielsh28 modified the milestones: v0.15.0, v0.16.0 Apr 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked Priority 2 Priority 2 Technical Debt Code that should be rewritten differently
Projects
None yet
Development

No branches or pull requests

3 participants