Complete the code to inject the service into the component constructor.
constructor(private [1]: CounterService) {}In Angular, services are injected using a variable name with camelCase, usually the service class name starting with lowercase.
Complete the code to call the increment method from the service on button click.
<button (click)="[1].increment()">Increase</button>
The service instance variable is used to call methods, not the class name.
Fix the error in the service method to update the count correctly.
increment() {
this.count [1] 1;
}The '+=' operator adds 1 to the current count value.
Fill both blanks to create a getter that returns the current count from the service.
get currentCount() {
return this.[1].[2];
}The getter accesses the count property from the injected service instance.
Fill all three blanks to create a service method that resets count to zero and emits the new value.
reset() {
this.[1] = [2];
this.[3].next(this.count);
}The method sets count to zero and emits the updated count via the countChanged subject.