This article covers following topics in details: Purpose of having pipes in Angular. Built in Pipes and its usage. How to create custom Pipes Purpose of having pipes in Angular. Pipes are used to format your data based on the requirement. Pipes donate from symbol “|” and you can use it inside the HTML template where you display the data with interpolation. Example if you want to format amount bases on some currency type you can use below expression. {{ amount | currency:'EUR' }} Pipes is simply a function which accept an input values such as integers, strings, arrays, and date and returns the transform value and display the same in the browser. Built in Pipes and its usage. There are several built in pipes in Angular. Uppercase pipe Lowercase pipe Date pipe Currency pipe Percent pipe Decimal pipe Slice pipe After setting up the environment and creating the example app we will try out each default pipe provided by Angular framework. Angular Related Articles: 1. How to set up An...
Here are some original articles, where you can find latest content on Angular, React Native, Java, HTML/CSS, AS400, DB2 and JavaScript. Since its founding in 2009, we’ve grown from an exhaustive source for consumer tech information on latest trends. Want to get more? We are here to help you.