summaryrefslogtreecommitdiffstats
path: root/catalog-ui/src/app/ng2/pipes/keys.pipe.ts
blob: 13bd26969c505201a0aff9e6677290040cdaf97a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
import { Pipe, PipeTransform } from '@angular/core';

@Pipe({name: 'keys'})
export class KeysPipe implements PipeTransform {
  transform(value, args:string[]) : any {
    let keys = [];
    for (let key in value) {
      keys.push(key);
    }
    return keys;
  }
}