July 2017
Intermediate to advanced
454 pages
10h 1m
English
A pipe instructs Angular in filtering or rendering the input data. A pipe transforms the input data according to the logic given in the pipe.
Now, let's generate a pipe using Angular CLI by executing the following statement:

Here, I created a pipe named bookfilter using Angular CLI. Note that it also created a test file, bookfilter.pipe.spec.ts, for writing test methods to assert the pipes. The code snippet of the bookfilter.pipe.ts is shown here:
import { Pipe, PipeTransform } from '@angular/core'; @Pipe({ name: 'bookfilter' }) export class BookfilterPipe implements PipeTransform { transform(value: any, args?: any): any { return ...Read now
Unlock full access