Skip to content

Commit 8e705ac

Browse files
committed
client/Source: Fix react-hooks/preserve-manual-memoization
This will be reported after the upcoming `eslint-plugin-react-hooks` bump: > Compilation Skipped: Existing memoization could not be preserved > > React Compiler has skipped optimizing this component because the existing manual memoization could not be preserved. The inferred dependencies did not match the manually specified dependencies, which could cause the value to change more or less frequently than expected. The inferred dependency was `setEditedSource`, but the source dependencies were [source]. Inferred different dependency than source.
1 parent b965464 commit 8e705ac

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

client/js/templates/Source.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -593,7 +593,7 @@ export default function Source({
593593

594594
const editOnClick = useCallback(
595595
(event) => handleEdit({ event, source, setEditedSource }),
596-
[source],
596+
[source, setEditedSource],
597597
);
598598

599599
const setDirty = useCallback(

0 commit comments

Comments
 (0)