Skip to content

Instantly share code, notes, and snippets.

@kagklis
Last active December 5, 2022 21:16
Show Gist options
  • Save kagklis/1d300ede9cb9b02fcd968f68a41193d4 to your computer and use it in GitHub Desktop.
Save kagklis/1d300ede9cb9b02fcd968f68a41193d4 to your computer and use it in GitHub Desktop.
@Component({
// ...
})
export class ChartComponent implements AfterViewInit, OnDestroy {
public dataLength: number = INIT_LENGTH;
public isLoading: boolean = true;
constructor(private dataService: DataService) { }
public modelChange(newValue: number): void {
this.dataLength = newValue;
this.isLoading = true;
this.dataService.updateDataLength(newValue);
}
// ...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment