Skip to content

fix: resolve synchronous state updates inside useEffect to prevent cascading renders in RobotAssistant#343

Open
DebasmitaBose0 wants to merge 1 commit into
Akshay473:mainfrom
DebasmitaBose0:fix/robot-assistant-cascading-renders
Open

fix: resolve synchronous state updates inside useEffect to prevent cascading renders in RobotAssistant#343
DebasmitaBose0 wants to merge 1 commit into
Akshay473:mainfrom
DebasmitaBose0:fix/robot-assistant-cascading-renders

Conversation

@DebasmitaBose0

Copy link
Copy Markdown
Contributor

Closes #342

Summary

Resolved ESLint react-hooks/set-state-in-effect violation inside the RobotAssistant component by wrapping the initial load logic in a requestAnimationFrame block.

Changes Made

  • Wrapped mount state initializers inside requestAnimationFrame.
  • Removed unused error parameter from the catch block to resolve secondary linter warnings.

Testing

  • Tested locally via npx eslint components/RobotAssistant.tsx showing 0 errors.
  • Verified client-side load states behave correctly without double-mount layout shifts.

Impact

Improves component load performance and maintains clean developer console logs.

Checklist

  • Code follows project standards
  • Tested locally
  • No unrelated changes included
  • Responsive design verified
  • Accessibility considered

@vercel

vercel Bot commented Jun 6, 2026

Copy link
Copy Markdown

@DebasmitaBose0 is attempting to deploy a commit to the akshay473's projects Team on Vercel.

A member of the Team first needs to authorize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[GSSOC] Fix Synchronous state updates causing cascading renders in RobotAssistant

1 participant