Skip to content

Fixes infinite rerender trigger loop in setup screen#23

Open
flleeppyy wants to merge 1 commit into
unitystation:masterfrom
flleeppyy:error-loop-fix
Open

Fixes infinite rerender trigger loop in setup screen#23
flleeppyy wants to merge 1 commit into
unitystation:masterfrom
flleeppyy:error-loop-fix

Conversation

@flleeppyy

@flleeppyy flleeppyy commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

This PR fixes like, 2 main things. Most important one was a repeated render call due to showError being a dependency in a useEffect. It also fixes showError and related functions not using useCallback and useMemo on context value, which caused a rerender every time one of its functions are called.

Here is an example of the issue involving a useEffect having showError as a dependency

BIG FAT EPILEPSY WARNING!!!

pudu-launcher_Bk509G9LyR.mp4

And here is the second issue concerning the FeedbackContext's exposed context functions not being wrapped in useCallback.

pudu-launcher_rHPAi8sQq2.mp4

@flleeppyy flleeppyy marked this pull request as ready for review June 16, 2026 01:34
@corp-0

corp-0 commented Jun 16, 2026

Copy link
Copy Markdown
Member

can you confirm if the code I pushed fixed this issue for you? At least in my repro, it worked

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants