Back to results for “Debugging”
Angular › Pipes (Built-in & Custom)

What are some of the most commonly used built in Angular pipes?

Beginner

Answer

Angular provides several useful built in pipes, including date for formatting dates, uppercase and lowercase for changing text casing, currency and number for formatting numeric values, and json for displaying a value's raw JSON representation, often useful for debugging.
<p>{{ today | date:'shortDate' }}</p>
<p>{{ name | uppercase }}</p>
<p>{{ price | currency:'USD' }}</p>
<pre>{{ userObject | json }}</pre>
Real-world example A dashboard formats a user's join date using the date pipe, displays their name in uppercase for a header, and shows their account balance using the currency pipe, all directly inside the template.

Common follow-ups: How would you customize the exact date format shown by the date pipe?;Why is the json pipe particularly useful during development and debugging?