Goals: the error banner and the "No goals yet" hint show at the same time

Open Beginner friendly
#3,872 6 comments 0 reactions 1 assignee View on GitHub

Maintainers usually reply within 1 day

@KartikeyG-world is already working on this.

Since Nov 29, 2026.

  • #3952 by @KartikeyG-world — open

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
73/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Domain
frontend

Research direction

Start in src/components/GoalTracker.tsx at the goals.length === 0 branch around line 627 and trace how the sync error and load result are represented. Add or update a component test for failed and successful empty loads. Done when a failed load shows the error and retry or refresh action without the empty hint, while a successful empty load shows the hint; coordinate with #3824, which also changes this file.

Written by the indexing model from the issue text.

Description

good first issue level 1 level:beginner status:assigned type:bug
Summary

When loading goals fails, the Goals card shows "Failed to load goals. Please try again." and "No goals yet. Set your first one below..." together. The second message is wrong: we don't know there are no goals, we just couldn't load them.

Where

src/components/GoalTracker.tsx (the goals.length === 0 branch around line 627 renders regardless of the sync error)

Expected outcome

While the load error is showing, don't show the empty-state hint (keep the retry/refresh action). Show the hint only after a successful load that returned no goals.

Acceptance criteria
  • A component test: a failed load shows the error and not the empty hint; a successful empty load shows the hint
  • Note: #3824 translates this file; coordinate or rebase on it
Dominant language
TypeScript
Stars
246
Forks
436
Avg merge
9h 33m
Merged PRs (30d)
213

Getting set up

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.

More from Priyanshu-byte-coder/devtrack

All issues in Priyanshu-byte-coder/devtrack

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.