How to concatanate html links and display them in div

In js file i have

 vm.text= (e) {
                                        var html = '<a ng-click="hello">' +  e.number+ '</a>';
                                        return html;
                                    }).join('  ||  ');

In html i have

                  <strong> {{vm.text}}</strong>

Above div display <a ng-click="hello">9253</a> || <a ng-click="hello">1025</a>

instead of just numbers w a hyperlink. I am guessing {{}} won’t allow html. How do i make it not do it and display links?


Try with <strong [innerHTML]="vm.text"></strong>.

Edit: I didn’t notice the ng- prefix, you should use ng-bind-html instead.