if I want to load the captcha by clicking refresh button its loading, but when we navigate to another page and clicking browser back button then captcha is going to disappear. How to resolve that problem that every time (either you refresh or clicking from browser back button) captcha should shown
import React, { useState } from "react";
import Recaptcha from "react-recaptcha";
export default function DropDown() {
const grecaptchaObject = window.grecaptcha;
function captchaVerify(response) {
if (response !== "") {
//some code
} else if ((response === "")) {
//some code
}
}
function recaptchaLoaded() {
}
return (
<>
<div>
<Recaptcha
sitekey="Your-Site-Key"
render="explicit"
onloadCallback={recaptchaLoaded}
verifyCallback={captchaVerify}
grecaptcha={grecaptchaObject}
/>
</div>
</>
);
}