Angular 2 HTML Binding

Angular 2 HTML Binding: You want to create an application that loads (html content) from a server and display them in you angular 2 component.

angular 2 html binding example
angular 2 html binding example

This mechanism is called: html binding

In angular 2 we can do the html binding with this syntax :


<div [innerHTML]="yourHTMLCodeFromThe server"> </div>