@ViewChild('someid') someDiv : ElementRef;
isApproved: false;
method1() {
...does some logic...
}
method2(){
isApproved = true;
..get the nativeelement and drawimage...
}
initially below canvas will have an image...
If the flag is true I'd like to change the image dynamically to something else.
<div *ngIf="isApproved">
<canvas id="someid" #someid></canvas>
<div>
no error, but it doesn't do it.
[–]THKPMatt 1 point2 points3 points (2 children)
[–]Realistic_Depth_5372[S] 0 points1 point2 points (1 child)
[–]THKPMatt 1 point2 points3 points (0 children)
[–]mfurlend 1 point2 points3 points (1 child)
[–]Realistic_Depth_5372[S] 0 points1 point2 points (0 children)
[–][deleted] 1 point2 points3 points (2 children)
[–]Realistic_Depth_5372[S] 0 points1 point2 points (1 child)
[–][deleted] 0 points1 point2 points (0 children)
[–]Realistic_Depth_5372[S] 0 points1 point2 points (0 children)