Angular 2 Observing a Service and find Results

As i do not write so much blog posts, i decided to write some just short snippets for known problems. This covers searching inside Object Array for Angular 2 and Typescript Finding index of an Array Entry with Angular 2 and Typescript Example of how to use Observer able service in Angular 2
//service is Observable = 'nameToFind';
GetGalleryPics(galleryId).subscribe((data:Picture[]) => {
        //success = data;
        //searching inside the array and find first entry 
        this.picture = => ==[0]
        let pictureIndex = => ==;
        console.log('this picture'+pictureIndex);



Beliebte Posts aus diesem Blog

So geht Timeboxing - video im Klartext