dozoisch/react-google-recaptcha

Next.js 13 App directory - Recaptcha not appearing after first load of <Link> component route change

2JJ1 opened this issue · 1 comments

2JJ1 commented

react-google-recaptcha version: 2.1.0
react-async-script version: 1.2.0

I've upgraded to the latest Next.js version, 13.0.2. I am using Google captcha v2.

Upon upgrading to Next.js 13 and utilizing the new app directory routing, the Google captcha no longer displays on first load from a Link component route change. It loads fine when refreshing the page. It loads fine when route changing with a plain tag.

This issue only exists in development mode. The issue does not exist on a live build.

2JJ1 commented

Switching to the react-google-recaptcha alpha version, v3, solves this issue