This is a simple console application demonstrating the use of Dependency Injection (DI) lifetimes in C#. It shows the differences between Singleton, Transient, and Scoped lifetimes.
- Clone the repository:
git clone https://github.com/Elanchezhiyan-P/DependencyInjectionExample.git- Navigate to the project directory:
cd DependencyInjectionExample - Restore the dependencies and run the application:
dotnet restore
dotnet runYou will see the output demonstrating the different behaviors of Singleton, Transient, and Scoped services.