UNPKG

react-grecaptcha-v3

Version:

Google Recaptcha V3 for React.js based application. Keep website performance high while prioritizing security.

18 lines 737 B
import { useContext } from "react"; import makeContextError from "./makeContextError"; import { Context } from "./ReCaptchaProvider"; var useSkipInjectionDelay = function() { var context = useContext(Context); return function() { var _ref; var forceInjectScript = (_ref = context === null || context === void 0 ? void 0 : context.injectScript.current) !== null && _ref !== void 0 ? _ref : null; if (forceInjectScript !== null) { forceInjectScript(); return null; } return makeContextError(""); }; }; var useSkipInjectionDelay_default = useSkipInjectionDelay; export { useSkipInjectionDelay_default as default }; //# sourceMappingURL=useSkipInjectionDelay.js.map