Repository navigation
fix: hook deps without exhaustive-deps disables - #931
Merged
Merged
Conversation
The reset ran in an effect that listed only isOpen, with the dependency check switched off. It now runs while rendering, when isOpen changes, so it still resets only on opening and keeps in-progress edits if the saved settings change while the dialog is open. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
The filter preload depended on a key built from the database names but read the array; it now reads the names back out of the key. The tree navigation fallback ran after every render to notice a vanished tab stop; it now watches the tree's rows with a MutationObserver keyed on the active row, which also sees rows a child removes on its own. Drops an unused eslint-disable directive in a types test. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g Closes #930
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Done by the
implementer-frontendlane. After this and #927, noreact-hooks/exhaustive-depsdisables are left in app code.Closes #930
Changes
isOpenas a dependency. Adding the setting it also read would have wiped in-progress edits whenever the saved settings changed. The effect is replaced with React's "adjust state when a prop changes" pattern, so the file no longer has an effect at all.databasesarray. That array is rebuilt on every render, so listing it as a dependency made a failing load retry forever. The effect now reads the names back from the key it depends on.activeKey, plus aMutationObserveron the tree. This also catches a row removed by a child component that re-renders on its own, which the old version missed.no-unused-expressionsdisable insrc/types/__tests__/index.test.ts.Tests
npm run test:unit: 3730 tests pass. SchemaTree and FormatterSettingsDialog tests ran 5 times in a row, all passing.Generated by Claude Code