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

In ShadowDom : NoElementException: No element to render on. #422

Open
AshMcConnell opened this issue Nov 11, 2022 · 1 comment
Open

In ShadowDom : NoElementException: No element to render on. #422

AshMcConnell opened this issue Nov 11, 2022 · 1 comment

Comments

@AshMcConnell
Copy link

AshMcConnell commented Nov 11, 2022

Hi Folks,

Having trouble when I have my Angular element in the shadow dom. It can't seem to find the element. I am loading in the javascript to execute JsBarcode from a server and creating a script element on the shadowRoot. It is executing, but it can't find the element in question.

Is there any way to work around this issue?

set scriptContents(javascript: string) {
        this._scriptContents = javascript;
        const scriptElement = document.createElement('script');
        

        scriptElement.textContent = javascript;
        this.elementRef.nativeElement.shadowRoot.appendChild(scriptElement);
    }
@arcanisgk
Copy link

same problem with BS4.X modals

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

2 participants