LabConnect-RCOS / LabConnect-RCOS/LabConnect-Frontend

Fix Maximum update depth exceeded on navbar component

Open
#43 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
2
Forks
3
Avg merge
15m
Merged PRs (30d)
2

Description

Warning: Maximum update depth exceeded. This can happen when a component calls setState inside useEffect, but useEffect either doesn't have a dependency array, or one of the dependencies changes on every render.
at MainNavigation (http://localhost:3000/static/js/bundle.js:2742:81)
at section
at GlobalContextProvider (http://localhost:3000/static/js/bundle.js:602:3)
at App (http://localhost:3000/static/js/bundle.js:61:51)
at Router (http://localhost:3000/static/js/bundle.js:293180:15)
at BrowserRouter (http://localhost:3000/static/js/bundle.js:291160:5)

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

Locate the MainNavigation component named in the warning and reproduce the issue in the frontend app. Trace the update loop around that component, then verify the navbar renders without the maximum update depth warning.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.