import { Pipe, PipeTransform } from '@angular/core';

@Pipe({ name: 'viewMenu' })
export class ViewMenuPipe implements PipeTransform {

    transform(menus: Array<any>, visible: boolean) {
        return menus.filter(item => { 
            return item.visible == visible;
        });
    }
}