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

@Pipe({name: 'else'})
export class ElsePipe implements PipeTransform {
  transform(value: any, alternative: string): string {
    if (value == undefined || value === null || (value + "") == "")
      return alternative;
    else
      return value
  }
}
