@Husko Inside your div
there is just text. Probably your javascript in index.html
changes the information into the game. I don’t know exactly what the function divs2applet()
does, but if it needs that the div
with the applet
class be already created, maybe you should try to call it inside your homepage component (because the component is still not created when you call the function in index.html
).
In home.ts:
declare var divs2applet;
@Component(...)
export class Home {
...
ngOnInit() {
divs2applet();
}
...
}
Also, it would be good to make the div
invisible until the game is loaded (so that the text is not shown right after the page is shown, before the game is loaded, unless the divs2applet()
already handles that).