json pipe
This is the documentation for Angular 7.
You can switch to the latest version Angular 10.
You can switch to the latest version Angular 10.
The json pipe is particularly helpful for debugging bindings:
Source
<div>{{data | json}}</div>
export class AppComponent {
data = {
field: 'value',
obj: {
innerField: '123',
},
};
}
Result
{
"field": "value",
"obj": {
"innerField": "123"
}
}