Skip to content

Commit e6fa5a5

Browse files
Copilothotlong
andcommitted
refactor: fix useEffect dependency array per code review feedback
Co-authored-by: hotlong <50353452+hotlong@users.noreply.github.com>
1 parent 4d7a611 commit e6fa5a5

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

apps/console/src/components/ViewConfigPanel.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ export function ViewConfigPanel({ open, onClose, mode = 'edit', activeView, obje
281281
useEffect(() => {
282282
setDraft({ ...effectiveActiveView });
283283
setIsDirty(mode === 'create');
284-
}, [mode === 'create' ? mode : activeView.id]);
284+
}, [mode, activeView.id]); // eslint-disable-line react-hooks/exhaustive-deps
285285

286286
// Focus the panel when it opens for keyboard accessibility
287287
useEffect(() => {

0 commit comments

Comments
 (0)