Video – Angular Interview : is Angular Service Singleton ?

One of the most popular Angular interview questions is, whether a service is singleton?

By default, when you create a service using the below CLI command,

ng g s app

AppService is singleton, however it can be re-provided to create more objects of it. Say, you again re provide AppService in one of the components, then Angular creates one more object of the AppService.

To learn more watch the video.


Discover more from Dhananjay Kumar

Subscribe to get the latest posts sent to your email.

Published by Dhananjay Kumar

Dhananjay Kumar is founder of NomadCoder and ng-India

Leave a comment

Discover more from Dhananjay Kumar

Subscribe now to keep reading and get access to the full archive.

Continue reading