dozoisch / dozoisch/react-google-recaptcha
Uncaught TypeError: Cannot read property 'postMessageId' of null at onPostMessage (iframe.js:1000)
- Dominant language
- JavaScript
- Stars
- 1.1k
- Forks
- 148
- PR merge metrics
- No merged PRs in 30d
Description
First of all thank you for awesome library.
When I add component to my form, it throw an error in console:
> Uncaught TypeError: Cannot read property 'postMessageId' of null
at onPostMessage (iframe.js:1000)
here is how I am using it:
```
import ReCAPTCHA from "react-google-recaptcha";
onChange = (value: any) => {
if (value) {
this.setState({ isCaptchaSuccess: true });
}
};
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reproducing the reported error with the shown ReCAPTCHA component usage and inspect iframe.js around line 1000, especially onPostMessage. Trace why the message handler receives null, then verify that the component renders without the uncaught TypeError and that onChange still receives the CAPTCHA value.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, react
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100