I need your help! I'm trying to import json file using angular. The only problem is that the json file is imported from other website and the html tags display as normal text. And here is my question, is there any chance to make those tags normal html not a visible text?
HTML:
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.1/angular.min.js"></script>
<script src="maincontroller.js" type="text/javascript"></script>
</head>
<body bgcolor="lightblue">
<div ng-app="mainApp" ng-controller="mainController">
<div id="content" style="width: 500px; height: 500px; background-color: green; ">
<div ng-repeat="content in contents">
<h2>{{content.title}}</h2>
<p>{{content.date}}</p>
<p>{{content.info}}</p>
<p>{{content.content}}</p>
<p>{{content.url}}</p>
</div>
</div>
</div>
</body>
</html>
maincontroller.js
var myapp=angular.module('mainApp',['ngSanitize']);
myapp.controller('mainController',function($scope,$http){
$http.get('/WP/?json=get_recent_posts').then(function(response, date){
$scope.contents = response.data.posts;
alert("success");
console.log(response)
}, function(error){
$scope.contents = [{title:"<h4> Error </h4>",date:"<p> JSON invalid </p>"}];
alert("error");
console.log(response)
})
});