I built my project using Angular 6 and TypeScript in Visual Studio Code. The browser being used is IE11.
Unfortunately, when I try to run the code written in app.component.html, it doesn't work as expected.
The HTML code causing the issue is:
<div>
<div >
<object ID="activexFirst" CLASSID="CLSID:xxxxx-xxx" width="300" height="200"></object>
</div>
<div>
<object ID="activeSencod" classid="CLSID:xxxxx-xxx" width="600" height="500"></object>
</div>
</div>
The TypeScript code in app.component.ts looks like this:
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css'],
encapsulation: ViewEncapsulation.None,
})
export class AppComponent implements AfterViewInit {
//todo..
}
Interestingly, if I write the code directly in Index.html, it works fine. How can I resolve this issue?