CopyPastor

Detecting plagiarism made easy.

Score: 0.7690858936657871; Reported for: String similarity Open both answers

Possible Plagiarism

Reposted on 2016-06-07
by Relu Mesaros

Original Post

Original - Posted on 2016-06-07
by Relu Mesaros



            
Present in both answers; Present only in the new answer; Present only in the old answer;

Here's an example
// the controller import { Component, OnInit } from '@angular/core'; import { Observable } from 'rxjs/Observable'; // your controller metadata // .... export class ListComponent implements OnInit { vehicles: Observable<Array<any>> ngOnInit() { this.vehicles = Observable.interval(2200).map(i=> [{name: 'car 1'},{name: 'car 2'}]) } } // in the template <div *ngFor='let vehicle of vehicles | async'> {{vehicle.name}} </div>
Here's an example
// in the service getVehicles(){ return Observable.interval(2200).map(i=> [{name: 'car 1'},{name: 'car 2'}]) } // in the controller vehicles: Observable<Array<any>> ngOnInit() { this.vehicles = this._vehicleService.getVehicles(); } // in template <div *ngFor='let vehicle of vehicles | async'> {{vehicle.name}} </div>

        
Present in both answers; Present only in the new answer; Present only in the old answer;