I've been looking for a nice way to display JSON and all the answers have a few solutions, but no matter what I try it just makes it one long line with no formatting. These are all the things I've tried.
<div>{{ jsonValue | json }}</div>
<pre>{{ jsonValue | json}}</pre>
<pre [innerHtml]="jsonValue"></pre>
import {PrettyJsonModule} from 'angular2-prettyjson';
<pre [innerHtml]="eligibilityView | prettyjson:3"></pre>
import {PrettyJsonModule} from 'angular2-prettyjson';
<pre>{{ eligibilityView | prettyjson:3 }}</pre>
From all the questions I've seen asked, one of these should work, but they all are only a single line with no formatting.