C# Dependency Injection

Open-source C# projects categorized as Dependency Injection
IoC C# Unity C# .NET

Top 23 C# Dependency Injection Projects

Dependency Injection
  • Autofac

    An addictive .NET IoC container

    Project mention: Modular Dependency Injection in .NET | dev.to | 2024-03-25

    When I was building application with .NET Framework I always used libraries like Autofac and SimpleInjector for dependency injection. I really liked to create modules (Packages in SimpleInjector) to achieve higher cohesion and lower coupling in my class libraries. I made a module for every class library in which all dependencies inside of that class library were registered. Why should my web application (for example) know if MyBeautifulService in MyBeautifulClassLibrary should be transient or singleton?

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • Scrutor

    Assembly scanning and decoration extensions for Microsoft.Extensions.DependencyInjection

  • VContainer

    The extra fast, minimum code size, GC-free DI (Dependency Injection) library running on Unity Game Engine.

    Project mention: VContainer VS Init(args) Lite - a user suggested alternative | libhunt.com/r/VContainer | 2024-05-05
  • Simple Injector

    An easy, flexible, and fast Dependency Injection library that promotes best practice to steer developers towards the pit of success.

    Project mention: Modular Dependency Injection in .NET | dev.to | 2024-03-25

    When I was building application with .NET Framework I always used libraries like Autofac and SimpleInjector for dependency injection. I really liked to create modules (Packages in SimpleInjector) to achieve higher cohesion and lower coupling in my class libraries. I made a module for every class library in which all dependencies inside of that class library were registered. Why should my web application (for example) know if MyBeautifulService in MyBeautifulClassLibrary should be transient or singleton?

  • jab

    C# Source Generator based dependency injection container implementation.

  • DryIoc

    DryIoc is fast, small, full-featured IoC Container for .NET

  • Reflex

    Minimal dependency injection framework for Unity (by gustavopsantos)

    Project mention: Another small hack I use for prototyping | /r/Unity3D | 2023-12-10

    There is also Reflex, a fast but more minimalistic solution. I haven't really heard much about people's experiences using this, so not sure how good it is in practice.

  • SaaSHub

    SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives

    SaaSHub logo
  • Device.Net

    A C# cross platform connected device framework

  • Extenject

    Dependency Injection Framework for Unity Game Engine (by Mathijs-Bakker)

  • Pure.DI

    Pure DI for .NET without frameworks!

  • Meet Grace

    Grace is a feature rich dependency injection container library (by ipjohnson)

  • Prism.Avalonia

    Prism framework support for Avalonia UI

  • FluentValidation.Blazor

    Fluent Validation-powered Blazor component for validating standard <EditForm> :milky_way: :white_check_mark:

  • Autofac.Extensions.DependencyInjection

    Autofac implementation of the interfaces in Microsoft.Extensions.DependencyInjection.Abstractions, the .NET Core dependency injection abstraction.

  • Stashbox

    A lightweight, fast, and portable dependency injection framework for .NET-based solutions.

  • Maui.Plugins.PageResolver

    A simple and lightweight page resolver for use in .NET MAUI projects

  • xaml-code-experiences

    A collection of the experiences I have collected during days of Xamarin and Wpf, while following the MVVM design pattern.

  • Medicine

    Code-driven component injection toolkit for Unity.

  • MailKitSimplified

    Send and receive emails easily, fluently, with one line of code for each operation.

  • xunit-dependency-injection

    :fire: A small library to help .NET developers leverage Microsoft's dependency injection framework in their Xunit-powered test projects

  • di-framework

    ↗ A Dependency Injection framework for Unity game engine.

  • Simplify.DI

    Simplify is an open-source set of lightweight .NET libraries that provide infrastructure for your applications. DI and mocking friendly. (by SimplifyNet)

  • SaveGame

    Keep track of your video games!

    Project mention: Show HN: Yet another video game tracker app | news.ycombinator.com | 2024-01-11
  • SaaSHub

    SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives

    SaaSHub logo
NOTE: The open source projects on this list are ordered by number of github stars. The number of mentions indicates repo mentiontions in the last 12 Months or since we started tracking (Dec 2020).

C# Dependency Injection discussion

Log in or Post with

C# Dependency Injection related posts

  • VContainer VS Init(args) Lite - a user suggested alternative

    2 projects | 5 May 2024
  • Zenject VS Init(args) Lite - a user suggested alternative

    2 projects | 5 May 2024
  • Modular Dependency Injection in .NET

    2 projects | dev.to | 25 Mar 2024
  • Another small hack I use for prototyping

    1 project | /r/Unity3D | 10 Dec 2023
  • Unity game architecture Part 1

    1 project | dev.to | 25 Sep 2023
  • I've been a Unity Dev for over 10 years. I recently joined this project that has some seasoned Unity vets but the player object looks like this. I know it mostly comes down to design patterns / choices, but does this seems like an excessive amount of components on one object?

    2 projects | /r/Unity3D | 25 May 2023
  • Singleton vs Dependency Injection vs Service Locator vs Scriptable Objects

    5 projects | /r/Unity3D | 22 May 2023
  • A note from our sponsor - InfluxDB
    www.influxdata.com | 24 Jun 2024
    Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality. Learn more →

Index

What are some of the best open-source Dependency Injection projects in C#? This list will help you:

Project Stars
1 Autofac 4,414
2 Scrutor 3,481
3 VContainer 1,764
4 Simple Injector 1,197
5 jab 1,011
6 DryIoc 975
7 Reflex 627
8 Device.Net 597
9 Extenject 483
10 Pure.DI 397
11 Meet Grace 335
12 Prism.Avalonia 269
13 FluentValidation.Blazor 233
14 Autofac.Extensions.DependencyInjection 189
15 Stashbox 136
16 Maui.Plugins.PageResolver 121
17 xaml-code-experiences 118
18 Medicine 84
19 MailKitSimplified 59
20 xunit-dependency-injection 39
21 di-framework 38
22 Simplify.DI 18
23 SaveGame 17

Sponsored
Power Real-Time Data Analytics at Scale
Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
www.influxdata.com