Has anyone succeeded getting the (non iframe) sign-up forms work with Next js or React?
I am trying to build my own customised form, but struggling due to errors coming from main.js lib related to removeClass (which I think it’s a jQuery dependency)?
Any sample code for a simple form using own styles in these frameworks would be appreciated
Hi @ahudavert , I’ve finally managed to get it working in React, but only with Google reCaptcha v2. I Couldn’t get Cloudflare Turnstile to work at all.
I’d stil like to ask for a sample code that decouple’s your UI from the form submission endpoint. I want to build my own custom form, but now I’m forced to use your divs and classes and main.js. The form breaks if I remove a single class that the main.js expects. Ideally we have a decoupled way, so I could also tap on supported npm packages for captcha/turnstile.
Anyway, for anyone that comes across this issue, here’s my BrevoForm.jsx component structure on how to load the captcha and Brevo’s main.js lib in a way that they properly reloads if you navigate away and back to the page (without that, due to the way React is caching the pages, those libs would not run if you navigate away and back to the page where the component is mounted).
Can I create the React contact form without the reCAPTCHA or similar? Because I cannot send an email through contact form until I authenticate this email into my Senders.