use typescript in html page code example Example: adding html in typescript this.htmlToAdd = '<div class="two">two</div>';