#Container element not found Error
12 messages · Page 1 of 1 (latest)
Because the DOM isn't there yet when ngOnInit is being called. https://angular.io/guide/lifecycle-hooks#lifecycle-hooks
so what can I do
Try to use ngAfterViewInit lifecycle hook
i tried
but nothing changed
<button type="submit" class="downloadButton" (click)="getTracks()">Get Tracks</button>
<div *ngFor="let track of trackDetails">
<div class="row" name="playersRow">
<div class="loopPlayer">
<div class="loopPlayerInfo">
<div class="row">
<div class="col-md-4" style="text-align: left !important;">{{track.title}} | {{track.desc}}</div>
<div class="col-md-8">
<div class="row">
<div class="col-md-8"></div>
<div class="col-md-2" style="padding-right: 0;">
<button class="downloadButton" (click)="stopWaveForm()">STOP</button>
</div>
<div class="col-md-2" style="padding-left: 0;">
<button class="downloadButton" (click)="playWaveForm(track.id)">
PLAY
</button>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-md-2">
<img src="{{track.photoUrl}}" alt="" class="loopPlayerPhoto" />
</div>
<div class="col-md-10">
<div class="loopPlayerWave">
<div id="T{{track.id}}"></div>
</div>
</div>
</div>
</div>
</div>
</div>
when I clıck the button all waves comes but I dont wanna clıck the button
when I open the page it must bu uplooded
could u write for me
I sent component and html file
g!codeblock @opal crest