Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't use this library into iFrame window. #974

Open
miteshsavani810 opened this issue Jan 16, 2025 · 0 comments
Open

Can't use this library into iFrame window. #974

miteshsavani810 opened this issue Jan 16, 2025 · 0 comments

Comments

@miteshsavani810
Copy link

On my react application, I want to show emoji picker in one of the component which loads into iFrame. When my component (which have <Picker ... /> component) loads into the iFrame then it throws below error

HTMLElement.ts:23 Uncaught TypeError: Failed to construct 'HTMLElement': Please use the 'new' operator, this DOM object constructor cannot be called as a function. at $efa000751917694d$export$2e2bcd8739ae039.$6f57cc9cd54c5aaa$export$2e2bcd8739ae039 [as constructor] (<anonymous>:3290:35) at $efa000751917694d$export$2e2bcd8739ae039.$26f27c338a96b1a6$export$2e2bcd8739ae039 [as constructor] (<anonymous>:3333:20) at new $efa000751917694d$export$2e2bcd8739ae039 (<anonymous>:4991:19) at <anonymous>:1:1

I think here HTMLElement is referring to parent window and hence it doesn't allow to create a object of it. I can access the custom element "em-emoji-picker" in the iFrame window but can't create a object of it.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant