I have a simple AngularJS app which consumes a JSON array of objects like this:
$scope.faq = [
{ id: 1, question: "What is the meaning of life?", answer: "42"},
{ id: 2, question: "What <em>is<em> 1+1?", answer: "4"}
]
In my HTML I have an ng-repeat with a basic filter coming from a text input like this
ng-repeat="qa in faq | filter:searchText"
The problem is I want the search to filter while ignoring the HTML tags in the JSON objects, so that searching for the phrase "what is" will return both objects instead of just the first one. How do I change the filter to do this?