Its printing html as it is(non html formatted data is shown in UI) Tried with ng-bind-html but didnt work Also tried using https://stackoverflow.com/a/25535684/6050814 not worked
$http({
method: 'POST',
url: 'http://.../req/get',
data: '{"source":"careers","code":"","reqId":406}'
}).then(function (response) {
$rootScope.myHTML = $sce.trustAsHtml(JSON.stringify(response.data.reqDetailsBO.reqTitle));
//alert(JSON.stringify(response.data.reqDetailsBO.jdDisplay));
//$scope.content = JSON.stringify(response.data.reqDetailsBO.jdDisplay)```;
});
//following is my html
<div ng-bind-html="myHTML"></div>
//these are dependencies I am injecting
angular.module('app.controllers', ['ionic.cloud','ngSanitize'])
//following is data I am trying to bind with
<span class="preheader" style="color: transparent; display: none; height: 0;
max-height: 0; max-width: 0; opacity: 0; overflow: hidden; mso-hide: all;
visibility: hidden; width: 0;">
Notification
</span>