New Aug 24, 2026

on click on element, react fails with "destroy is not a function"

Libraries, Frameworks, etc. All from Newest questions tagged reactjs - Stack Overflow View on click on element, react fails with "destroy is not a function" on stackoverflow.com

This occurred after the recent browser update to chrome/edge 150, with the following code:

React.useEffect(() => endElementRef.current?.scrollIntoView(false), [endElementRef.current, lastByte]);

The error shown when using the dev build is

26-08-05 13:25:39 ERROR [MainWrapper] - uncaught JavaScript exception
{columnNumber: 11, exception: TypeError: destroy is not a function
at commitHookEffectListUnmount (https://example…, lineNumber: 26942, message: 'Uncaught TypeError: destroy is not a function', source: '[https://example.com/path/to/bundle.js'}] Error Component Stack [wall of stacktrace here]

What has happened ?

Scroll to top