The difference between Nest.js and Angular DI
Even if Nest.js is widely based on Angular, there is a major difference between them. In Angular, each service is a singleton, which is the same as Nest.js, but there is a possibility to ask Angular to provide a new instance of the service.
To do that in Angular, you can use the providers
property of the @Injectable()
decorator to have a new instance of a provider registered in the module and available only for this component. That can be useful to have to avoid overwriting some properties through different components.