Can you generate sine wave data continuously from an Angular service and inject it into a component?
Clash Royale CLAN TAG #URR8PPP Can you generate sine wave data continuously from an Angular service and inject it into a component? I have a component which has an injected service to retrieve static mock data. I would like to add the ability to generate data at a variable frequency and send the new (appended, time series) data to the component as it is generated. I can't for the life of me figure out how to accomplish this. All I know for sure is that the data object for the component must be immutable. plotter.component.ts: import { Component, OnInit } from '@angular/core'; import { MockDataService } from '../../services/mock-data/mock-data.service'; @Component({ selector: 'app-plotter', templateUrl: './plotter.component.html', styleUrls: ['./plotter.component.css'] }) export class PlotterComponent implements OnInit { single: any; multi: any; // rt needs to be an immutable object array // rt needs to be updated with data from ...