react-linkify-it icon indicating copy to clipboard operation
react-linkify-it copied to clipboard

getKey causes Google Translate to blow up React

Open ericchernuka opened this issue 6 months ago • 1 comments

We've got light usage of the project, but we've noticed that because we have a Fragment and the children have a dynamic key on every re-render, React blows up when a user is using Google Translate. I've implemented a full fix for keys and better React conventions around valid React elements/array's that I was wondering if you'd be open to a PR to alleviate this issue. Since the project hasn't had many updates lately, we're reaching out before possibly forking.

ericchernuka avatar May 25 '26 15:05 ericchernuka

Sure I'll take a look. If you can also link to any example showing the issue that would be great.

anantoghosh avatar May 25 '26 20:05 anantoghosh

Hey! 👋

I've opened PR #74 to fix this issue. It resolves the React crash triggered by Google Translate by addressing the dynamic key problem on re-renders. The PR also improves the code to adhere to better React conventions regarding valid elements and arrays.

We wanted to share this fix before potentially forking, especially given the lack of recent activity. Thanks for your work on this project!

webbrain-one avatar Aug 08 '26 02:08 webbrain-one