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

Integrated in angular/typescript #67

Open
tungUAS opened this issue Jan 21, 2022 · 2 comments
Open

Integrated in angular/typescript #67

tungUAS opened this issue Jan 21, 2022 · 2 comments

Comments

@tungUAS
Copy link

tungUAS commented Jan 21, 2022

hey sir, thank you for the beatiful animation. I would like to add it to my chatbot written in Angular.
I added this code to ngOnInit():
this.siriWave = new SiriWave({
container: document.querySelector("#myWave"),
cover: true,
height: 100,
style: "ios9"
});

But somehow i am getting the error: Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element'. Can you please help me out ?

@tungUAS tungUAS changed the title angular/typescript Integrated in angular/typescript Jan 21, 2022
@tungUAS tungUAS closed this as completed Jan 21, 2022
@tungUAS tungUAS reopened this Jan 21, 2022
@kopiro
Copy link
Owner

kopiro commented Feb 7, 2022

Hello! Does the element document.querySelector("#myWave") exists in the DOM?

@Nuajan
Copy link

Nuajan commented Mar 10, 2022

@tungUAS verify you did not place container inside an *ngIf block and replace it with a [hidden] in that cause. I was having the same issue and that solved it for me.
Give it a try.

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

3 participants