akash-network / akash-network/console

Delay app rendering till settings are loaded

Open
#600 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

tech-debt
Dominant language
TypeScript
Stars
264
Forks
94
Avg merge
18h 49m
Merged PRs (30d)
297

Description

We use quite some tweaks to make sure we get our settings available. For instance all the chain data fetched via react query hooks depends on url got from settings. This causes checks in every such hook with weird logic. These hooks are used on every page and cause loading states anyway. So we need to make sure app doesn't load till we have all the data for the app to function properly.

Acceptance criteria:

  • make sure the app rendering is delayed till settings are fetched
  • app should be in the loading state meanwhile
  • refactor settings to make sure interface guarantees required props presence
  • remove settings values checks across the app

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with apps/deploy-web/src/context/SettingsProvider/SettingsProviderContext.tsx and trace how settings are fetched before pages and React Query hooks render. Identify the app entry point and settings checks across the app. Done means rendering waits for fetched settings, shows a loading state meanwhile, required settings props are guaranteed, and redundant checks are removed.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.