import { Pipe , PipeTransform } from '@angular/core' ; @ Pipe ( { name : 'filter' , } ) export class FilterPipe implements PipeTransform { transform ( items , filterCallback ) { return items . filter ( ( item ) => filterCallback ( item ) ) ; } }